diff options
author | Len Brown <len.brown@intel.com> | 2016-06-17 01:22:44 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-07-10 17:00:12 +0200 |
commit | ba8268330dc18d309a39175ea4d2c5d86c2cef09 (patch) | |
tree | c31c3d6907e56df464e6bdc8401d810ee7dcc80c /arch | |
parent | fc5f3ac24720012909c224a63ca3217f4759967d (diff) | |
download | op-kernel-dev-ba8268330dc18d309a39175ea4d2c5d86c2cef09.zip op-kernel-dev-ba8268330dc18d309a39175ea4d2c5d86c2cef09.tar.gz |
x86/tsc_msr: Identify Intel-specific code
try_msr_calibrate_tsc() is currently Intel-specific,
and should not execute on any other vendor's parts.
Signed-off-by: Len Brown <len.brown@intel.com>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/1fe23c052826bdcfeb3d45045aa02246078cb5a7.1466138954.git.len.brown@intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kernel/tsc_msr.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/x86/kernel/tsc_msr.c b/arch/x86/kernel/tsc_msr.c index 6aa0f4d..4ec5e56 100644 --- a/arch/x86/kernel/tsc_msr.c +++ b/arch/x86/kernel/tsc_msr.c @@ -86,6 +86,9 @@ unsigned long try_msr_calibrate_tsc(void) unsigned long res; int cpu_index; + if (boot_cpu_data.x86_vendor != X86_VENDOR_INTEL) + return 0; + cpu_index = match_cpu(boot_cpu_data.x86, boot_cpu_data.x86_model); if (cpu_index < 0) return 0; |