diff options
author | Baolin Wang <baolin.wang@linaro.org> | 2018-05-07 17:28:27 +0800 |
---|---|---|
committer | James Hogan <jhogan@kernel.org> | 2018-05-14 23:58:23 +0100 |
commit | 09adad17191942cac01ccfbb897b976ac8f42c22 (patch) | |
tree | 779d55a325e59896c032ce5591db659ad6378ed2 /arch/mips/sibyte/swarm/rtc_xicor1241.c | |
parent | d7c72c57b144997241f6933b6548ea86ced1b844 (diff) | |
download | blackbird-op-linux-09adad17191942cac01ccfbb897b976ac8f42c22.tar.gz blackbird-op-linux-09adad17191942cac01ccfbb897b976ac8f42c22.zip |
MIPS: Convert read_persistent_clock() to read_persistent_clock64()
Since struct timespec is not y2038 safe on 32bit machines, this patch
converts read_persistent_clock() to read_persistent_clock64() using
struct timespec64, as well as converting mktime() to mktime64().
Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Huacai Chen <chenhc@lemote.com>
Cc: Paul Burton <paul.burton@mips.com>
Cc: linux-mips@linux-mips.org
Signed-off-by: James Hogan <jhogan@kernel.org>
Diffstat (limited to 'arch/mips/sibyte/swarm/rtc_xicor1241.c')
-rw-r--r-- | arch/mips/sibyte/swarm/rtc_xicor1241.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/mips/sibyte/swarm/rtc_xicor1241.c b/arch/mips/sibyte/swarm/rtc_xicor1241.c index 50a82c495427..a2121c1345a9 100644 --- a/arch/mips/sibyte/swarm/rtc_xicor1241.c +++ b/arch/mips/sibyte/swarm/rtc_xicor1241.c @@ -168,7 +168,7 @@ int xicor_set_time(unsigned long t) return 0; } -unsigned long xicor_get_time(void) +time64_t xicor_get_time(void) { unsigned int year, mon, day, hour, min, sec, y2k; unsigned long flags; @@ -201,7 +201,7 @@ unsigned long xicor_get_time(void) year += (y2k * 100); - return mktime(year, mon, day, hour, min, sec); + return mktime64(year, mon, day, hour, min, sec); } int xicor_probe(void) |