mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] x86: trivial - reenable Skipped synchronization message once at boot
@ 2009-12-17  1:43 Pallipadi, Venkatesh
  0 siblings, 0 replies; only message in thread
From: Pallipadi, Venkatesh @ 2009-12-17  1:43 UTC (permalink / raw)
  To: Ingo Molnar, Thomas Gleixner, H Peter Anvin; +Cc: linux-kernel, Mike Travis


commit 9b3660a5 changed below

-               printk_once(KERN_INFO "Skipping synchronization checks
                as TSC is
+               if (cpu == (nr_cpu_ids-1) || system_state !=
SYSTEM_BOOTING)
+                       pr_info(
+                       "Skipped synchronization checks as TSC is
reliable.\n");

which results in "Skipped synchronization checks as TSC is reliable"
message missing from my dmesg. The problem is that nr_cpu_ids is number
of possible CPUs, and courtesy extra disabled cpus in my bios, that
number is higher than real cpus.

Change the check to num_present_cpus() - 1, which gets us back to old
behavior of printing this message once at boot.

Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
---
 arch/x86/kernel/tsc_sync.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/tsc_sync.c b/arch/x86/kernel/tsc_sync.c
index 0aa5fed..6fe5184 100644
--- a/arch/x86/kernel/tsc_sync.c
+++ b/arch/x86/kernel/tsc_sync.c
@@ -114,9 +114,11 @@ void __cpuinit check_tsc_sync_source(int cpu)
 		return;
 
 	if (boot_cpu_has(X86_FEATURE_TSC_RELIABLE)) {
-		if (cpu == (nr_cpu_ids-1) || system_state != SYSTEM_BOOTING)
+		if (cpu == (num_present_cpus() - 1) ||
+		    system_state != SYSTEM_BOOTING) {
 			pr_info(
 			"Skipped synchronization checks as TSC is reliable.\n");
+		}
 		return;
 	}
 
-- 
1.6.0.6


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

only message in thread, other threads:[~2009-12-17  1:44 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-17  1:43 [PATCH] x86: trivial - reenable Skipped synchronization message once at boot Pallipadi, Venkatesh

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®