Commit dd5ff34
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 cd3d030 commit dd5ff34
1 file changed
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
571 | 571 | | |
572 | 572 | | |
573 | 573 | | |
574 | | - | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
575 | 579 | | |
576 | 580 | | |
577 | 581 | | |
| |||
0 commit comments