lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <841757364754f8d0a8834982ca16da10a6a44d72.1666275945.git.maciej.szmigiero@oracle.com>
Date:   Thu, 20 Oct 2022 16:26:09 +0200
From:   "Maciej S. Szmigiero" <mail@...iej.szmigiero.name>
To:     John Stultz <jstultz@...gle.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Stephen Boyd <sboyd@...nel.org>
Cc:     linux-kernel@...r.kernel.org
Subject: [PATCH][RESEND] clocksource: downgrade messages about skipping watchdog check under load

From: "Maciej S. Szmigiero" <maciej.szmigiero@...cle.com>

Since commit c86ff8c55b8a ("clocksource: Avoid accidental unstable marking of clocksources")
the watchdog check is skipped if two consecutive watchdog reads are too far
apart.

This might happen, for example, when the system is under heavy load, so it
isn't a totally unexpected condition.

Since some systems are prone to producing significant number of these
messages when the system is constantly under heavy load downgrade their log
level to "debug" to avoid filling the kernel log in such case.

These messages can then still be enabled via dyndbg mechanism in case
someone really needs to see them.

Signed-off-by: Maciej S. Szmigiero <maciej.szmigiero@...cle.com>
---
 kernel/time/clocksource.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c
index cee5da1e54c41..ff99b25bc1aec 100644
--- a/kernel/time/clocksource.c
+++ b/kernel/time/clocksource.c
@@ -236,8 +236,8 @@ static enum wd_read_status cs_watchdog_read(struct clocksource *cs, u64 *csnow,
 					      watchdog->shift);
 		if (wd_delay <= WATCHDOG_MAX_SKEW) {
 			if (nretries > 1 || nretries >= max_cswd_read_retries) {
-				pr_warn("timekeeping watchdog on CPU%d: %s retried %d times before success\n",
-					smp_processor_id(), watchdog->name, nretries);
+				pr_debug("timekeeping watchdog on CPU%d: %s retried %d times before success\n",
+					 smp_processor_id(), watchdog->name, nretries);
 			}
 			return WD_READ_SUCCESS;
 		}
@@ -262,10 +262,10 @@ static enum wd_read_status cs_watchdog_read(struct clocksource *cs, u64 *csnow,
 	return WD_READ_UNSTABLE;
 
 skip_test:
-	pr_info("timekeeping watchdog on CPU%d: %s wd-wd read-back delay of %lldns\n",
-		smp_processor_id(), watchdog->name, wd_seq_delay);
-	pr_info("wd-%s-wd read-back delay of %lldns, clock-skew test skipped!\n",
-		cs->name, wd_delay);
+	pr_debug("timekeeping watchdog on CPU%d: %s wd-wd read-back delay of %lldns\n",
+		 smp_processor_id(), watchdog->name, wd_seq_delay);
+	pr_debug("wd-%s-wd read-back delay of %lldns, clock-skew test skipped!\n",
+		 cs->name, wd_delay);
 	return WD_READ_SKIP;
 }
 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ