diff options
| author | Kumar Gala <galak@kernel.crashing.org> | 2011-05-19 00:36:21 -0500 |
|---|---|---|
| committer | Kumar Gala <galak@kernel.crashing.org> | 2011-05-19 00:36:21 -0500 |
| commit | 134c428e5a31f2d5ed3a70ba20dac83895ec8b82 (patch) | |
| tree | 0fb28accbf09171b8a1ca792361f4160434529e8 /drivers/rtc/rtc-pcap.c | |
| parent | a0496d450ab8c17f6c4d86979b1f6ba486fe9365 (diff) | |
| parent | c560bbceaf6b06e52f1ef20131b76a3fdc0a2c19 (diff) | |
Merge remote branch 'benh/merge' into benh-next
Diffstat (limited to 'drivers/rtc/rtc-pcap.c')
| -rw-r--r-- | drivers/rtc/rtc-pcap.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-pcap.c b/drivers/rtc/rtc-pcap.c index a633abc4289..cd4f198cc2e 100644 --- a/drivers/rtc/rtc-pcap.c +++ b/drivers/rtc/rtc-pcap.c @@ -151,6 +151,8 @@ static int __devinit pcap_rtc_probe(struct platform_device *pdev) pcap_rtc->pcap = dev_get_drvdata(pdev->dev.parent); + platform_set_drvdata(pdev, pcap_rtc); + pcap_rtc->rtc = rtc_device_register("pcap", &pdev->dev, &pcap_rtc_ops, THIS_MODULE); if (IS_ERR(pcap_rtc->rtc)) { @@ -158,7 +160,6 @@ static int __devinit pcap_rtc_probe(struct platform_device *pdev) goto fail_rtc; } - platform_set_drvdata(pdev, pcap_rtc); timer_irq = pcap_to_irq(pcap_rtc->pcap, PCAP_IRQ_1HZ); alarm_irq = pcap_to_irq(pcap_rtc->pcap, PCAP_IRQ_TODA); @@ -177,6 +178,7 @@ fail_alarm: fail_timer: rtc_device_unregister(pcap_rtc->rtc); fail_rtc: + platform_set_drvdata(pdev, NULL); kfree(pcap_rtc); return err; } |
