rtc: remove nvmem_config
authorAlexandre Belloni <alexandre.belloni@bootlin.com>
Mon, 12 Feb 2018 22:47:34 +0000 (23:47 +0100)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Thu, 1 Mar 2018 09:49:23 +0000 (10:49 +0100)
Because nvmem_config is only used and copied at nvmem registration, remove
it from struct rtc_device.

All the rtc drivers using nvmem are now calling rtc_nvmem_register
directly.

Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
drivers/rtc/class.c
include/linux/rtc.h

index 0cab397f6e378a45127b1d7d4d0351ba0fe6422f..5a5ab4fa14f9fb7a1c9d7900f02084a2b586d228 100644 (file)
@@ -454,8 +454,6 @@ int __rtc_register_device(struct module *owner, struct rtc_device *rtc)
 
        rtc_proc_add_device(rtc);
 
-       rtc_nvmem_register(rtc, rtc->nvmem_config);
-
        rtc->registered = true;
        dev_info(rtc->dev.parent, "registered as %s\n",
                 dev_name(&rtc->dev));
index fbc92fff7c2e4db1ee9b55bfebd25b796832ab13..37b041f72f8d949180d0abf1c8fdaeb61ddc8711 100644 (file)
@@ -145,7 +145,6 @@ struct rtc_device {
 
        bool registered;
 
-       struct nvmem_config *nvmem_config;
        struct nvmem_device *nvmem;
        /* Old ABI support */
        bool nvram_old_abi;