Skip to content

Commit

Permalink
rtc: sprd: Add RTC hardware range
Browse files Browse the repository at this point in the history
The SC27xx RTC can support dates from 1970-01-01 00:00:00 to 2149-06-06
23:59:59.

Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
  • Loading branch information
Baolin Wang authored and Alexandre Belloni committed May 3, 2018
1 parent 369a30a commit 149aa91
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/rtc/rtc-sc27xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -631,6 +631,8 @@ static int sprd_rtc_probe(struct platform_device *pdev)
}

rtc->rtc->ops = &sprd_rtc_ops;
rtc->rtc->range_min = 0;
rtc->rtc->range_max = 5662310399LL;
ret = rtc_register_device(rtc->rtc);
if (ret) {
dev_err(&pdev->dev, "failed to register rtc device\n");
Expand Down

0 comments on commit 149aa91

Please sign in to comment.