[PATCH 0/3] ASoC: core: Two step component registration

Pierre-Louis Bossart pierre-louis.bossart at linux.intel.com
Fri Jul 31 17:07:23 CEST 2020



On 7/31/20 9:41 AM, Cezary Rojewski wrote:
> Provide a mechanism for true two-step component registration. This
> mimics device registration flow where initialization is the first step
> while addition goes as second in line. Drivers may choose to modify
> component's fields before registering component to ASoC subsystem via
> snd_soc_add_component.

I must admit I don't see where this might be used for Intel platforms, 
we've been happily using snd_soc_register_component() without hitting 
limitations.

Also the only two uses of snd_soc_add_component() seem mainly driven by 
memory allocation - and avoiding a devm_kzalloc in 
snd_soc_register_component().

Out of curiosity, can you provide an example where this two-step would 
be required or beneficial? Thanks!

> Patchset achieves status quo - behavior of snd_soc_register_component
> remains unchanged.
> 
> Cezary Rojewski (3):
>    ASoC: core: Relocate and expose snd_soc_component_initialize
>    ASoC: core: Simplify snd_soc_component_initialize declaration
>    ASoC: core: Two step component registration
> 
>   include/sound/soc-component.h         |  3 --
>   include/sound/soc.h                   | 11 +++---
>   sound/soc/soc-component.c             | 16 ---------
>   sound/soc/soc-core.c                  | 52 +++++++++++++++++----------
>   sound/soc/soc-generic-dmaengine-pcm.c | 14 +++++---
>   sound/soc/stm/stm32_adfsdm.c          |  9 +++--
>   6 files changed, 55 insertions(+), 50 deletions(-)
> 


More information about the Alsa-devel mailing list