From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757258AbcGJSKv (ORCPT ); Sun, 10 Jul 2016 14:10:51 -0400 Received: from terminus.zytor.com ([198.137.202.10]:53486 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755293AbcGJSKt (ORCPT ); Sun, 10 Jul 2016 14:10:49 -0400 Date: Sun, 10 Jul 2016 11:10:21 -0700 From: tip-bot for Len Brown Message-ID: Cc: torvalds@linux-foundation.org, peterz@infradead.org, hpa@zytor.com, tglx@linutronix.de, len.brown@intel.com, linux-kernel@vger.kernel.org, mingo@kernel.org Reply-To: torvalds@linux-foundation.org, peterz@infradead.org, hpa@zytor.com, tglx@linutronix.de, len.brown@intel.com, linux-kernel@vger.kernel.org, mingo@kernel.org In-Reply-To: <1fe23c052826bdcfeb3d45045aa02246078cb5a7.1466138954.git.len.brown@intel.com> References: <1fe23c052826bdcfeb3d45045aa02246078cb5a7.1466138954.git.len.brown@intel.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/timers] x86/tsc_msr: Identify Intel-specific code Git-Commit-ID: ba8268330dc18d309a39175ea4d2c5d86c2cef09 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: ba8268330dc18d309a39175ea4d2c5d86c2cef09 Gitweb: http://git.kernel.org/tip/ba8268330dc18d309a39175ea4d2c5d86c2cef09 Author: Len Brown AuthorDate: Fri, 17 Jun 2016 01:22:44 -0400 Committer: Ingo Molnar CommitDate: Sun, 10 Jul 2016 17:00:12 +0200 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 Reviewed-by: Thomas Gleixner Cc: Linus Torvalds Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1fe23c052826bdcfeb3d45045aa02246078cb5a7.1466138954.git.len.brown@intel.com Signed-off-by: Ingo Molnar --- arch/x86/kernel/tsc_msr.c | 3 +++ 1 file changed, 3 insertions(+) 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;