[alsa-devel] [PATCH v3 3/5] ASoC: qcom: add sdm845 sound card support

Srinivas Kandagatla srinivas.kandagatla at linaro.org
Mon Jul 9 16:02:11 CEST 2018



On 09/07/18 13:41, Mark Brown wrote:
>> AFAIU, The issue with that mechanism or EPROBEDEFER is that it works only
>> for first time.. for the second time(restart usecase) there are no hooks
>> like bind/unbind.
> This is not the case, the card will be unbound at the ASoC level when
> any of the components are removed and then probed again when they
> reappear.
> 
I did try this and It works only for first time! May be am missing 
something!

snd_soc_component_del_unlocked() unregisters the sound card totally. so 
for the second time (After DSP stop) there is no registered sound card 
in place.. Am not sure how this is supposed to work?

The reason I think it works for the first time is because of EPROBEDEFER 
from the machine driver.

Here are the steps I do with DSP:

Step1: Start DSP, can see sound card after all the services are ON.
Step2: Stop DSP, there is no audio card.
Step3: Start DSP, I can see all the components in debugfs but not the 
sound card.

This is what I do w.r.t code:
 From machine driver in snd_soc_register_card() in probe()
 From Audio services driver snd_soc_register_component() in probe() and
snd_soc_unregister_component() in remove()

When DSP is stopped the audio services disappear and 
snd_soc_unregister_component() is invoked.


thanks,
srini


More information about the Alsa-devel mailing list