aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2013-11-12 18:11:00 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2013-11-12 22:09:31 -0500
commita2726061920f43f594e03236d694c71f77adc6a2 (patch)
treea79a1af413011536801ebbcfa59b58b4c08b1d2c
parentc8b18da7769af46455180a61e7c292ec514e47e7 (diff)
drivers/rtc/rtc-pl03x.c: remove unnecessary amba_set_drvdata()
Driver core clears the driver data to NULL after device_release or on probe failure, so just remove it from here. The relevant driver core change was commit 0998d0631001 ("device-core: Ensure drvdata = NULL when no driver is bound"). Signed-off-by: Michal Simek <michal.simek@xilinx.com> Cc: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--drivers/rtc/rtc-pl030.c2
-rw-r--r--drivers/rtc/rtc-pl031.c2
2 files changed, 0 insertions, 4 deletions
diff --git a/drivers/rtc/rtc-pl030.c b/drivers/rtc/rtc-pl030.c
index 22bacdbf9139..a804f758ac6d 100644
--- a/drivers/rtc/rtc-pl030.c
+++ b/drivers/rtc/rtc-pl030.c
@@ -153,8 +153,6 @@ static int pl030_remove(struct amba_device *dev)
153{ 153{
154 struct pl030_rtc *rtc = amba_get_drvdata(dev); 154 struct pl030_rtc *rtc = amba_get_drvdata(dev);
155 155
156 amba_set_drvdata(dev, NULL);
157
158 writel(0, rtc->base + RTC_CR); 156 writel(0, rtc->base + RTC_CR);
159 157
160 free_irq(dev->irq[0], rtc); 158 free_irq(dev->irq[0], rtc);
diff --git a/drivers/rtc/rtc-pl031.c b/drivers/rtc/rtc-pl031.c
index e3b25712b659..99181fff88fd 100644
--- a/drivers/rtc/rtc-pl031.c
+++ b/drivers/rtc/rtc-pl031.c
@@ -305,7 +305,6 @@ static int pl031_remove(struct amba_device *adev)
305{ 305{
306 struct pl031_local *ldata = dev_get_drvdata(&adev->dev); 306 struct pl031_local *ldata = dev_get_drvdata(&adev->dev);
307 307
308 amba_set_drvdata(adev, NULL);
309 free_irq(adev->irq[0], ldata); 308 free_irq(adev->irq[0], ldata);
310 rtc_device_unregister(ldata->rtc); 309 rtc_device_unregister(ldata->rtc);
311 iounmap(ldata->base); 310 iounmap(ldata->base);
@@ -391,7 +390,6 @@ out_no_irq:
391 rtc_device_unregister(ldata->rtc); 390 rtc_device_unregister(ldata->rtc);
392out_no_rtc: 391out_no_rtc:
393 iounmap(ldata->base); 392 iounmap(ldata->base);
394 amba_set_drvdata(adev, NULL);
395out_no_remap: 393out_no_remap:
396 kfree(ldata); 394 kfree(ldata);
397out: 395out: