]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - drivers/rtc/hctosys.c
Merge tag 'xtensa-20181115' of git://github.com/jcmvbkbc/linux-xtensa
[linux.git] / drivers / rtc / hctosys.c
index e79f2a181ad24217a3e3bc232593184b82d494fd..b9ec4a16db1f6b6fd113c5661a28aa0e9153eeaa 100644 (file)
@@ -50,8 +50,10 @@ static int __init rtc_hctosys(void)
        tv64.tv_sec = rtc_tm_to_time64(&tm);
 
 #if BITS_PER_LONG == 32
-       if (tv64.tv_sec > INT_MAX)
+       if (tv64.tv_sec > INT_MAX) {
+               err = -ERANGE;
                goto err_read;
+       }
 #endif
 
        err = do_settimeofday64(&tv64);