Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ba826833 authored by Len Brown's avatar Len Brown Committed by Ingo Molnar
Browse files

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: default avatarLen Brown <len.brown@intel.com>
Reviewed-by: default avatarThomas 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: default avatarIngo Molnar <mingo@kernel.org>
parent fc5f3ac2
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -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;