rtc: rework rtc_register_device() resource management
[linux-2.6-microblaze.git] / drivers / rtc / rtc-cpcap.c
index 38d576b..afc8fcb 100644 (file)
@@ -301,7 +301,7 @@ static int cpcap_rtc_probe(struct platform_device *pdev)
                /* ignore error and continue without wakeup support */
        }
 
-       return rtc_register_device(rtc->rtc_dev);
+       return devm_rtc_register_device(rtc->rtc_dev);
 }
 
 static const struct of_device_id cpcap_rtc_of_match[] = {