summaryrefslogtreecommitdiff
path: root/drivers/rtc/rtc-ls1x.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/rtc/rtc-ls1x.c')
-rw-r--r--drivers/rtc/rtc-ls1x.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/rtc/rtc-ls1x.c b/drivers/rtc/rtc-ls1x.c
index 045af1135e48..de86f9fabc11 100644
--- a/drivers/rtc/rtc-ls1x.c
+++ b/drivers/rtc/rtc-ls1x.c
@@ -87,16 +87,17 @@
static int ls1x_rtc_read_time(struct device *dev, struct rtc_time *rtm)
{
- unsigned long v, t;
+ unsigned long v;
+ time64_t t;
v = readl(SYS_TOYREAD0);
t = readl(SYS_TOYREAD1);
memset(rtm, 0, sizeof(struct rtc_time));
- t = mktime((t & LS1X_YEAR_MASK), ls1x_get_month(v),
+ t = mktime64((t & LS1X_YEAR_MASK), ls1x_get_month(v),
ls1x_get_day(v), ls1x_get_hour(v),
ls1x_get_min(v), ls1x_get_sec(v));
- rtc_time_to_tm(t, rtm);
+ rtc_time64_to_tm(t, rtm);
return 0;
}