diff options
author | Tushar Behera <tushar.behera@linaro.org> | 2014-05-21 08:52:19 +0530 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-05-22 00:20:11 +0100 |
commit | 7253e354e712d2cab7b640c62c8bb82653447c44 (patch) | |
tree | ef95602d86ec3ba29060f7bbd45cfc7808ab545f /sound/soc/samsung/s3c24xx-i2s.c | |
parent | 55313bd3b09b68ce28e328e9dde79bfc389ea921 (diff) | |
download | op-kernel-dev-7253e354e712d2cab7b640c62c8bb82653447c44.zip op-kernel-dev-7253e354e712d2cab7b640c62c8bb82653447c44.tar.gz |
ASoC: samsung: Use devm_snd_soc_register_component
Replaced snd_soc_register_component with its devres equivalent,
devm_snd_soc_register_component.
Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/soc/samsung/s3c24xx-i2s.c')
-rw-r--r-- | sound/soc/samsung/s3c24xx-i2s.c | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/sound/soc/samsung/s3c24xx-i2s.c b/sound/soc/samsung/s3c24xx-i2s.c index 8380443..4a6d206 100644 --- a/sound/soc/samsung/s3c24xx-i2s.c +++ b/sound/soc/samsung/s3c24xx-i2s.c @@ -475,34 +475,22 @@ static int s3c24xx_iis_dev_probe(struct platform_device *pdev) { int ret = 0; - ret = snd_soc_register_component(&pdev->dev, &s3c24xx_i2s_component, - &s3c24xx_i2s_dai, 1); + ret = devm_snd_soc_register_component(&pdev->dev, + &s3c24xx_i2s_component, &s3c24xx_i2s_dai, 1); if (ret) { pr_err("failed to register the dai\n"); return ret; } ret = samsung_asoc_dma_platform_register(&pdev->dev); - if (ret) { + if (ret) pr_err("failed to register the dma: %d\n", ret); - goto err; - } - return 0; -err: - snd_soc_unregister_component(&pdev->dev); return ret; } -static int s3c24xx_iis_dev_remove(struct platform_device *pdev) -{ - snd_soc_unregister_component(&pdev->dev); - return 0; -} - static struct platform_driver s3c24xx_iis_driver = { .probe = s3c24xx_iis_dev_probe, - .remove = s3c24xx_iis_dev_remove, .driver = { .name = "s3c24xx-iis", .owner = THIS_MODULE, |