Commit e925a6b1 authored by Fabio Estevam's avatar Fabio Estevam Committed by Mark Brown

ASoC: designware_i2s: 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: default avatarFabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent d8dfad38
...@@ -421,13 +421,11 @@ static int dw_i2s_probe(struct platform_device *pdev) ...@@ -421,13 +421,11 @@ static int dw_i2s_probe(struct platform_device *pdev)
dw_i2s_dai, 1); dw_i2s_dai, 1);
if (ret != 0) { if (ret != 0) {
dev_err(&pdev->dev, "not able to register dai\n"); dev_err(&pdev->dev, "not able to register dai\n");
goto err_set_drvdata; goto err_clk_disable;
} }
return 0; return 0;
err_set_drvdata:
dev_set_drvdata(&pdev->dev, NULL);
err_clk_disable: err_clk_disable:
clk_disable(dev->clk); clk_disable(dev->clk);
err_clk_put: err_clk_put:
...@@ -440,7 +438,6 @@ static int dw_i2s_remove(struct platform_device *pdev) ...@@ -440,7 +438,6 @@ static int dw_i2s_remove(struct platform_device *pdev)
struct dw_i2s_dev *dev = dev_get_drvdata(&pdev->dev); struct dw_i2s_dev *dev = dev_get_drvdata(&pdev->dev);
snd_soc_unregister_component(&pdev->dev); snd_soc_unregister_component(&pdev->dev);
dev_set_drvdata(&pdev->dev, NULL);
clk_put(dev->clk); clk_put(dev->clk);
......
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