]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
rtc: rx8581: add RTC range
authorAlexandre Belloni <alexandre.belloni@bootlin.com>
Thu, 17 May 2018 20:33:26 +0000 (22:33 +0200)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Thu, 17 May 2018 20:37:14 +0000 (22:37 +0200)
The rx8581 can support dates from 01/01/2000 to 31/12/2099.

Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
drivers/rtc/rtc-rx8581.c

index c64911a0853119db0677e4fcc62fef27890dd426..c5ffd30ca6728eb7c24fda750935d553a64d5292 100644 (file)
@@ -291,6 +291,8 @@ static int rx8581_probe(struct i2c_client *client,
                return PTR_ERR(rx8581->rtc);
 
        rx8581->rtc->ops = &rx8581_rtc_ops;
+       rx8581->rtc->range_min = RTC_TIMESTAMP_BEGIN_2000;
+       rx8581->rtc->range_max = RTC_TIMESTAMP_END_2099;
 
        return rtc_register_device(rx8581->rtc);
 }