summaryrefslogtreecommitdiff
path: root/drivers/rtc/imxdi.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/rtc/imxdi.c')
-rw-r--r--drivers/rtc/imxdi.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/rtc/imxdi.c b/drivers/rtc/imxdi.c
index 0d7d736..17519ce 100644
--- a/drivers/rtc/imxdi.c
+++ b/drivers/rtc/imxdi.c
@@ -192,7 +192,7 @@ int rtc_get(struct rtc_time *tmp)
}
now = __raw_readl(&data.regs->dtcmr);
- to_tm(now, tmp);
+ rtc_to_tm(now, tmp);
err:
return rc;
@@ -209,8 +209,7 @@ int rtc_set(struct rtc_time *tmp)
goto err;
}
- now = mktime(tmp->tm_year, tmp->tm_mon, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
+ now = rtc_mktime(tmp);
/* zero the fractional part first */
rc = DI_WRITE_WAIT(0, dtclr);
if (rc == 0)