From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752023AbcFFNk5 (ORCPT ); Mon, 6 Jun 2016 09:40:57 -0400 Received: from terminus.zytor.com ([198.137.202.10]:36710 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750929AbcFFNkz (ORCPT ); Mon, 6 Jun 2016 09:40:55 -0400 Date: Mon, 6 Jun 2016 06:40:39 -0700 From: "tip-bot for Dr. David Alan Gilbert" Message-ID: Cc: hpa@zytor.com, mingo@kernel.org, tglx@linutronix.de, dgilbert@redhat.com, linux-kernel@vger.kernel.org Reply-To: hpa@zytor.com, mingo@kernel.org, tglx@linutronix.de, dgilbert@redhat.com, linux-kernel@vger.kernel.org In-Reply-To: <1464976859-21850-1-git-send-email-dgilbert@redhat.com> References: <1464976859-21850-1-git-send-email-dgilbert@redhat.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/urgent] x86/msr: Use the proper trace point conditional for writes Git-Commit-ID: 08dd8cd06ed95625b9e2fac43c78fcb45b7eaf94 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: 08dd8cd06ed95625b9e2fac43c78fcb45b7eaf94 Gitweb: http://git.kernel.org/tip/08dd8cd06ed95625b9e2fac43c78fcb45b7eaf94 Author: Dr. David Alan Gilbert AuthorDate: Fri, 3 Jun 2016 19:00:59 +0100 Committer: Thomas Gleixner CommitDate: Mon, 6 Jun 2016 15:33:39 +0200 x86/msr: Use the proper trace point conditional for writes The msr tracing for writes is incorrectly conditional on the read trace. Fixes: 7f47d8cc039f "x86, tracing, perf: Add trace point for MSR accesses" Signed-off-by: Dr. David Alan Gilbert Cc: stable@vger.kernel.org Cc: ak@linux.intel.com Link: http://lkml.kernel.org/r/1464976859-21850-1-git-send-email-dgilbert@redhat.com Signed-off-by: Thomas Gleixner --- arch/x86/include/asm/msr.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/include/asm/msr.h b/arch/x86/include/asm/msr.h index 7dc1d8f..b5fee97 100644 --- a/arch/x86/include/asm/msr.h +++ b/arch/x86/include/asm/msr.h @@ -122,7 +122,7 @@ notrace static inline void native_write_msr(unsigned int msr, "2:\n" _ASM_EXTABLE_HANDLE(1b, 2b, ex_handler_wrmsr_unsafe) : : "c" (msr), "a"(low), "d" (high) : "memory"); - if (msr_tracepoint_active(__tracepoint_read_msr)) + if (msr_tracepoint_active(__tracepoint_write_msr)) do_trace_write_msr(msr, ((u64)high << 32 | low), 0); } @@ -141,7 +141,7 @@ notrace static inline int native_write_msr_safe(unsigned int msr, : "c" (msr), "0" (low), "d" (high), [fault] "i" (-EIO) : "memory"); - if (msr_tracepoint_active(__tracepoint_read_msr)) + if (msr_tracepoint_active(__tracepoint_write_msr)) do_trace_write_msr(msr, ((u64)high << 32 | low), err); return err; }