diff options
Diffstat (limited to 'drivers/rtc/rtc-s3c.c')
-rw-r--r-- | drivers/rtc/rtc-s3c.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/rtc/rtc-s3c.c b/drivers/rtc/rtc-s3c.c index 0b495e8b8e66..7afd373b9595 100644 --- a/drivers/rtc/rtc-s3c.c +++ b/drivers/rtc/rtc-s3c.c | |||
@@ -421,8 +421,6 @@ static void s3c_rtc_enable(struct platform_device *pdev, int en) | |||
421 | 421 | ||
422 | static int s3c_rtc_remove(struct platform_device *dev) | 422 | static int s3c_rtc_remove(struct platform_device *dev) |
423 | { | 423 | { |
424 | platform_set_drvdata(dev, NULL); | ||
425 | |||
426 | s3c_rtc_setaie(&dev->dev, 0); | 424 | s3c_rtc_setaie(&dev->dev, 0); |
427 | 425 | ||
428 | clk_unprepare(rtc_clk); | 426 | clk_unprepare(rtc_clk); |
@@ -549,23 +547,20 @@ static int s3c_rtc_probe(struct platform_device *pdev) | |||
549 | 0, "s3c2410-rtc alarm", rtc); | 547 | 0, "s3c2410-rtc alarm", rtc); |
550 | if (ret) { | 548 | if (ret) { |
551 | dev_err(&pdev->dev, "IRQ%d error %d\n", s3c_rtc_alarmno, ret); | 549 | dev_err(&pdev->dev, "IRQ%d error %d\n", s3c_rtc_alarmno, ret); |
552 | goto err_alarm_irq; | 550 | goto err_nortc; |
553 | } | 551 | } |
554 | 552 | ||
555 | ret = devm_request_irq(&pdev->dev, s3c_rtc_tickno, s3c_rtc_tickirq, | 553 | ret = devm_request_irq(&pdev->dev, s3c_rtc_tickno, s3c_rtc_tickirq, |
556 | 0, "s3c2410-rtc tick", rtc); | 554 | 0, "s3c2410-rtc tick", rtc); |
557 | if (ret) { | 555 | if (ret) { |
558 | dev_err(&pdev->dev, "IRQ%d error %d\n", s3c_rtc_tickno, ret); | 556 | dev_err(&pdev->dev, "IRQ%d error %d\n", s3c_rtc_tickno, ret); |
559 | goto err_alarm_irq; | 557 | goto err_nortc; |
560 | } | 558 | } |
561 | 559 | ||
562 | clk_disable(rtc_clk); | 560 | clk_disable(rtc_clk); |
563 | 561 | ||
564 | return 0; | 562 | return 0; |
565 | 563 | ||
566 | err_alarm_irq: | ||
567 | platform_set_drvdata(pdev, NULL); | ||
568 | |||
569 | err_nortc: | 564 | err_nortc: |
570 | s3c_rtc_enable(pdev, 0); | 565 | s3c_rtc_enable(pdev, 0); |
571 | clk_disable_unprepare(rtc_clk); | 566 | clk_disable_unprepare(rtc_clk); |