提交 113f9017 编写于 作者: W Wei Yongjun 提交者: Rafael J. Wysocki

cpufreq: brcmstb-avs-cpufreq: remove unnecessary platform_set_drvdata()

The driver core clears the driver data to NULL after device_release
or on probe failure. Thus, it is not needed to manually clear the
device driver data to NULL.
Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com>
Acked-by: NViresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 a69261e4
...@@ -878,7 +878,6 @@ static int brcm_avs_prepare_init(struct platform_device *pdev) ...@@ -878,7 +878,6 @@ static int brcm_avs_prepare_init(struct platform_device *pdev)
iounmap(priv->avs_intr_base); iounmap(priv->avs_intr_base);
unmap_base: unmap_base:
iounmap(priv->base); iounmap(priv->base);
platform_set_drvdata(pdev, NULL);
return ret; return ret;
} }
...@@ -1042,7 +1041,6 @@ static int brcm_avs_cpufreq_remove(struct platform_device *pdev) ...@@ -1042,7 +1041,6 @@ static int brcm_avs_cpufreq_remove(struct platform_device *pdev)
priv = platform_get_drvdata(pdev); priv = platform_get_drvdata(pdev);
iounmap(priv->base); iounmap(priv->base);
iounmap(priv->avs_intr_base); iounmap(priv->avs_intr_base);
platform_set_drvdata(pdev, NULL);
return 0; return 0;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册