Commit 77aea716 authored by Sachin Kamat's avatar Sachin Kamat Committed by Mark Brown

ASoC: SPEAr spdif_out: Use devm_snd_soc_register_component

devm_snd_soc_register_component makes code simpler.
Signed-off-by: default avatarSachin Kamat <sachin.kamat@linaro.org>
Acked-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 5fb7680b
...@@ -307,18 +307,11 @@ static int spdif_out_probe(struct platform_device *pdev) ...@@ -307,18 +307,11 @@ static int spdif_out_probe(struct platform_device *pdev)
dev_set_drvdata(&pdev->dev, host); dev_set_drvdata(&pdev->dev, host);
ret = snd_soc_register_component(&pdev->dev, &spdif_out_component, ret = devm_snd_soc_register_component(&pdev->dev, &spdif_out_component,
&spdif_out_dai, 1); &spdif_out_dai, 1);
return ret; return ret;
} }
static int spdif_out_remove(struct platform_device *pdev)
{
snd_soc_unregister_component(&pdev->dev);
return 0;
}
#ifdef CONFIG_PM #ifdef CONFIG_PM
static int spdif_out_suspend(struct device *dev) static int spdif_out_suspend(struct device *dev)
{ {
...@@ -357,7 +350,6 @@ static SIMPLE_DEV_PM_OPS(spdif_out_dev_pm_ops, spdif_out_suspend, \ ...@@ -357,7 +350,6 @@ static SIMPLE_DEV_PM_OPS(spdif_out_dev_pm_ops, spdif_out_suspend, \
static struct platform_driver spdif_out_driver = { static struct platform_driver spdif_out_driver = {
.probe = spdif_out_probe, .probe = spdif_out_probe,
.remove = spdif_out_remove,
.driver = { .driver = {
.name = "spdif-out", .name = "spdif-out",
.owner = THIS_MODULE, .owner = THIS_MODULE,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment