diff options
author | Simon Glass <sjg@chromium.org> | 2015-04-20 12:37:19 -0600 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2015-05-05 20:58:20 -0600 |
commit | 714209832db1064886680b138f1abf9ce235b2c3 (patch) | |
tree | 6a786a91f13c0e154fb9f6a3068229ad1d2f5326 /drivers/rtc/imxdi.c | |
parent | 9f9276c34cbbf67fd1b3788f0be326b47fc69123 (diff) | |
download | u-boot-imx-714209832db1064886680b138f1abf9ce235b2c3.zip u-boot-imx-714209832db1064886680b138f1abf9ce235b2c3.tar.gz u-boot-imx-714209832db1064886680b138f1abf9ce235b2c3.tar.bz2 |
dm: rtc: Rename mktime() and reduce the number of parameters
Most callers unpack the structure and pass each member. It seems better to
pass the whole structure instead, as with the C library. Also add an rtc_
prefix.
Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Heiko Schocher <hs@denx.de>
Diffstat (limited to 'drivers/rtc/imxdi.c')
-rw-r--r-- | drivers/rtc/imxdi.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/rtc/imxdi.c b/drivers/rtc/imxdi.c index e89034d..17519ce 100644 --- a/drivers/rtc/imxdi.c +++ b/drivers/rtc/imxdi.c @@ -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) |