Commit 0fe47d3
committed
ASoC: SOF: topology: allocate string for tuples
The existing code point tuples[*num_copied_tuples].value.s to elem->string
which works fine if there is only one topology is handled and all the
tuples are handled before the topology fw is released. However, we will
handle multiple topologies and the tuples may be used after the topology
fw is release. Ues devm_kasprintf to allocate the string for the tuples
to avoid invalid access.
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>1 parent b0dc371 commit 0fe47d3
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
571 | 571 | | |
572 | 572 | | |
573 | 573 | | |
574 | | - | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
575 | 577 | | |
576 | 578 | | |
577 | 579 | | |
| |||
0 commit comments