Skip to content

Commit

Permalink
ASoC: pxa: pxa2xx-ac97.c: use devm_snd_soc_register_component()
Browse files Browse the repository at this point in the history
We have devm_xxx version of snd_soc_register_component,
let's use it.

Signed-off-by: Kuninori Morimoto <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
  • Loading branch information
morimoto authored and broonie committed Jul 2, 2019
1 parent dcbe6ed commit 4b9b73b
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sound/soc/pxa/pxa2xx-ac97.c
Original file line number Diff line number Diff line change
Expand Up @@ -250,15 +250,14 @@ static int pxa2xx_ac97_dev_probe(struct platform_device *pdev)
* driver to do interesting things with the clocking to get us up
* and running.
*/
return snd_soc_register_component(&pdev->dev, &pxa_ac97_component,
return devm_snd_soc_register_component(&pdev->dev, &pxa_ac97_component,
pxa_ac97_dai_driver, ARRAY_SIZE(pxa_ac97_dai_driver));
}

static int pxa2xx_ac97_dev_remove(struct platform_device *pdev)
{
struct ac97_controller *ctrl = platform_get_drvdata(pdev);

snd_soc_unregister_component(&pdev->dev);
snd_ac97_controller_unregister(ctrl);
pxa2xx_ac97_hw_remove(pdev);
return 0;
Expand Down

0 comments on commit 4b9b73b

Please sign in to comment.