[alsa-devel] [PATCH 02/16] ASoC: au1x: ac97c: use devm_snd_soc_register_component()
Mark Brown
broonie at kernel.org
Mon Sep 10 15:59:43 CEST 2018
On Fri, Sep 07, 2018 at 01:00:32AM +0000, Kuninori Morimoto wrote:
> @@ -288,8 +288,6 @@ static int au1xac97c_drvremove(struct platform_device *pdev)
> {
> struct au1xpsc_audio_data *ctx = platform_get_drvdata(pdev);
>
> - snd_soc_unregister_component(&pdev->dev);
> -
> WR(ctx, AC97_ENABLE, EN_D); /* clock off, disable */
>
> ac97c_workdata = NULL; /* MDEV */
This will mean that instead of unregistering the component so nothing
can use the hardware then disabling the hardware we'll do things the
other way around so there's a race where we may break anything that
tries to use the driver just as we're unregistring, possibly causing the
system to hang or something depending on what happens if you try to
access the disabled IPs.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20180910/10a74c11/attachment-0001.sig>
More information about the Alsa-devel
mailing list