Re: [PATCH] ALSA: core: Fix control device release issue
From: Markus Elfring
Date: Tue Jun 02 2020 - 08:25:18 EST
> We use snd_pcm_add_usr_ctls() in component's .pcm_new(),
> unfortunately snd_soc_dapm_add_routes() meets error during
> adding card->dapm_routes/of_dapm_routes, it will goto probe_end
> to call soc_cleanup_card_resources().
>
> The commit dc82e52492f6 ("ALSA: core: Assure control device
> to be registered at last") will make pcm device release is
> prior to control device release, but the control device needs
> to use pcm pointor, which is already freed by pcm device release.
I suggest to improve this change description.
Regards,
Markus