[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180725200018.23722-1-pasha.tatashin@oracle.com>
Date: Wed, 25 Jul 2018 16:00:18 -0400
From: Pavel Tatashin <pasha.tatashin@...cle.com>
To: steven.sistare@...cle.com, daniel.m.jordan@...cle.com,
x86@...nel.org, linux-kernel@...r.kernel.org, tglx@...utronix.de,
sboyd@...nel.org, pasha.tatashin@...cle.com, john.stultz@...aro.org
Subject: [PATCH] timekeeping: warning when persistent clock is not available
On arches with no persistent clock a message like this is printed during
boot:
[ 0.000000] Persistent clock returned invalid value
The value is not invalid: it simply zero meaning no persistent clock and
the absence of persistent clock should be quietly accepted.
Fixes: 3eca993740b8 ("timekeeping: Replace read_boot_clock64() with read_persistent_wall_and_boot_offset()")
Signed-off-by: Pavel Tatashin <pasha.tatashin@...cle.com>
---
kernel/time/timekeeping.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
index edf5da78a449..f3b22f456fac 100644
--- a/kernel/time/timekeeping.c
+++ b/kernel/time/timekeeping.c
@@ -1557,7 +1557,7 @@ void __init timekeeping_init(void)
if (timespec64_valid_strict(&wall_time) &&
timespec64_to_ns(&wall_time) > 0) {
persistent_clock_exists = true;
- } else {
+ } else if (timespec64_to_ns(&wall_time) != 0) {
pr_warn("Persistent clock returned invalid value");
wall_time = (struct timespec64){0};
}
--
2.18.0
Powered by blists - more mailing lists