Hi,
I'm requesting comments to this small series to enable multiple different kcontrol types for a single widget.
Currently asoc allows to define and parse multiple same type kcontrols for single widget. So you can have for example two volume controls in a widget but not for example one byte and one enum control. I personally had this kind of use case where I wanted to set filter coefficients with bytes and something else with an enum in one processing widget.
I don't have that good perspective on the asoc history on this part so I don't know is there some reason for the existing logic or is it just ok to change it like in this series. I've been told some drivers use virtual widget for this kind of situation, so they define two widget's (one virtual) with separate controls, but in reality bind the controls into the same component in lower level. Or can we just actually use separate types in one widget?
First patch is changing the kcontrol_type uint in dapm widget to a pointer to hold an array of kcontrol types and then creating these different types in a loop in dapm widget load. Second patch is me utilizing this in sof driver.
Changes since v1: - don't add kcontrol type to core i.e. to kcontrol and kcontrol_news - extend existing dapm widget kcontrol_type into holding an array of types
Jaska Uimonen (2): ASoC: soc-dapm: enable use of multiple control types ASoC: SOF: topology: use individual kcontrol types
include/sound/soc-topology.h | 2 +- sound/soc/soc-topology.c | 466 +++++++++++++++++------------------ sound/soc/sof/topology.c | 13 +- 3 files changed, 232 insertions(+), 249 deletions(-)