rtc: Allow child drivers
authorSimon Glass <sjg@chromium.org>
Sun, 18 Nov 2018 15:14:35 +0000 (08:14 -0700)
committerSimon Glass <sjg@chromium.org>
Thu, 29 Nov 2018 16:30:05 +0000 (09:30 -0700)
Some RTC chips have child drivers, e.g. to provide access to their
non-volatile RAM. Scan for these when binding.

Signed-off-by: Simon Glass <sjg@chromium.org>
drivers/rtc/rtc-uclass.c

index c676f0ff359a1bc8572a4c4214dfc625d4d4adfe..a0a238aeddaddc41325a1e5580fcac2b77fcb3b5 100644 (file)
@@ -122,4 +122,5 @@ int rtc_write32(struct udevice *dev, unsigned int reg, u32 value)
 UCLASS_DRIVER(rtc) = {
        .name           = "rtc",
        .id             = UCLASS_RTC,
+       .post_bind      = dm_scan_fdt_dev,
 };