ASoC: sti_uniperif: Ensure component is unregistered when unload module

Use devm_snd_soc_register_component to ensure component is unregistered
when unload the module.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Axel Lin 2015-08-29 23:06:32 +08:00 committed by Mark Brown
parent 36cc093520
commit e12909107c
1 changed files with 3 additions and 3 deletions

View File

@ -224,9 +224,9 @@ static int sti_uniperiph_probe(struct platform_device *pdev)
dev_set_drvdata(&pdev->dev, priv);
ret = snd_soc_register_component(&pdev->dev,
&sti_uniperiph_dai_component,
priv->dai, 1);
ret = devm_snd_soc_register_component(&pdev->dev,
&sti_uniperiph_dai_component,
priv->dai, 1);
if (ret < 0)
return ret;