From: Fabio Estevam Date: Fri, 23 Aug 2013 21:14:45 +0000 (-0300) Subject: ASoC: fsl_spdif: Remove unnecessary dev_set_drvdata() X-Git-Tag: accepted/tizen/common/20141203.182822~1038^2~170^2~3^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5af407cd365c8aab8a20e66aa6e4bc4a4983979e;p=platform%2Fkernel%2Flinux-arm64.git ASoC: fsl_spdif: Remove unnecessary dev_set_drvdata() Driver core clears the driver data to NULL after device_release or on probe failure, so just remove it from here. Signed-off-by: Fabio Estevam Reviewed-by: Nicolin Chen Signed-off-by: Mark Brown --- diff --git a/sound/soc/fsl/fsl_spdif.c b/sound/soc/fsl/fsl_spdif.c index 42a4382..a8ef46a 100644 --- a/sound/soc/fsl/fsl_spdif.c +++ b/sound/soc/fsl/fsl_spdif.c @@ -1184,7 +1184,7 @@ static int fsl_spdif_probe(struct platform_device *pdev) &spdif_priv->cpu_dai_drv, 1); if (ret) { dev_err(&pdev->dev, "failed to register DAI: %d\n", ret); - goto error_dev; + return ret; } ret = imx_pcm_dma_init(pdev); @@ -1197,8 +1197,6 @@ static int fsl_spdif_probe(struct platform_device *pdev) error_component: snd_soc_unregister_component(&pdev->dev); -error_dev: - dev_set_drvdata(&pdev->dev, NULL); return ret; } @@ -1207,7 +1205,6 @@ static int fsl_spdif_remove(struct platform_device *pdev) { imx_pcm_dma_exit(pdev); snd_soc_unregister_component(&pdev->dev); - dev_set_drvdata(&pdev->dev, NULL); return 0; }