mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [tip: timers/core] clocksource: Reduce the default clocksource_watchdog() retries to 2
@ 2022-01-10 13:06 tip-bot2 for Waiman Long
  0 siblings, 0 replies; only message in thread
From: tip-bot2 for Waiman Long @ 2022-01-10 13:06 UTC (permalink / raw)
  To: linux-tip-commits; +Cc: Paul E. McKenney, Waiman Long, x86, linux-kernel

The following commit has been merged into the timers/core branch of tip:

Commit-ID:     1a5620671a1b6fd9cc08761677d050f1702f910c
Gitweb:        https://git.kernel.org/tip/1a5620671a1b6fd9cc08761677d050f1702f910c
Author:        Waiman Long <longman@redhat.com>
AuthorDate:    Thu, 18 Nov 2021 14:14:37 -05:00
Committer:     Paul E. McKenney <paulmck@kernel.org>
CommitterDate: Tue, 30 Nov 2021 17:22:29 -08:00

clocksource: Reduce the default clocksource_watchdog() retries to 2

With the previous patch, there is an extra watchdog read in each retry.
Now the total number of clocksource reads is increased to 4 per iteration.
In order to avoid increasing the clock skew check overhead, the default
maximum number of retries is reduced from 3 to 2 to maintain the same 12
clocksource reads in the worst case.

Suggested-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Waiman Long <longman@redhat.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
---
 Documentation/admin-guide/kernel-parameters.txt | 4 ++--
 kernel/time/clocksource.c                       | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index 9725c54..3ea934b 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -603,8 +603,8 @@
 	clocksource.max_cswd_read_retries= [KNL]
 			Number of clocksource_watchdog() retries due to
 			external delays before the clock will be marked
-			unstable.  Defaults to three retries, that is,
-			four attempts to read the clock under test.
+			unstable.  Defaults to two retries, that is,
+			three attempts to read the clock under test.
 
 	clocksource.verify_n_cpus= [KNL]
 			Limit the number of CPUs checked for clocksources
diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c
index bcad1a1..b7e52a6 100644
--- a/kernel/time/clocksource.c
+++ b/kernel/time/clocksource.c
@@ -199,7 +199,7 @@ void clocksource_mark_unstable(struct clocksource *cs)
 	spin_unlock_irqrestore(&watchdog_lock, flags);
 }
 
-ulong max_cswd_read_retries = 3;
+ulong max_cswd_read_retries = 2;
 module_param(max_cswd_read_retries, ulong, 0644);
 EXPORT_SYMBOL_GPL(max_cswd_read_retries);
 static int verify_n_cpus = 8;

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-01-10 13:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-10 13:06 [tip: timers/core] clocksource: Reduce the default clocksource_watchdog() retries to 2 tip-bot2 for Waiman Long

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®