[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <tip-99770737ca7e3ebc14e66460a69b7032de9421e1@git.kernel.org>
Date: Fri, 21 Aug 2015 00:45:30 -0700
From: tip-bot for Ingo Molnar <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: ray.huang@....com, john.stultz@...aro.org, luto@...capital.net,
ralf@...ux-mips.org, bp@...en8.de, kvm@...r.kernel.org,
lenb@...nel.org, dvlasenk@...hat.com, luto@...nel.org,
tglx@...utronix.de, peterz@...radead.org, bp@...e.de,
linux-kernel@...r.kernel.org, hpa@...or.com,
torvalds@...ux-foundation.org, mingo@...nel.org, brgerst@...il.com
Subject: [tip:x86/asm] x86/asm/tsc: Add rdtscll() merge helper
Commit-ID: 99770737ca7e3ebc14e66460a69b7032de9421e1
Gitweb: http://git.kernel.org/tip/99770737ca7e3ebc14e66460a69b7032de9421e1
Author: Ingo Molnar <mingo@...nel.org>
AuthorDate: Fri, 21 Aug 2015 08:33:53 +0200
Committer: Ingo Molnar <mingo@...nel.org>
CommitDate: Fri, 21 Aug 2015 08:35:42 +0200
x86/asm/tsc: Add rdtscll() merge helper
Some in-flight code makes use of the old rdtscll() (now removed), provide a wrapper
for a kernel cycle to smooth the transition to rdtsc().
( We use the safest variant, rdtsc_ordered(), which has barriers - this adds another
incentive to remove the wrapper in the future. )
Cc: Andy Lutomirski <luto@...nel.org>
Cc: Borislav Petkov <bp@...e.de>
Cc: Andy Lutomirski <luto@...capital.net>
Cc: Borislav Petkov <bp@...en8.de>
Cc: Brian Gerst <brgerst@...il.com>
Cc: Denys Vlasenko <dvlasenk@...hat.com>
Cc: H. Peter Anvin <hpa@...or.com>
Cc: Huang Rui <ray.huang@....com>
Cc: John Stultz <john.stultz@...aro.org>
Cc: Len Brown <lenb@...nel.org>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Ralf Baechle <ralf@...ux-mips.org>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: kvm ML <kvm@...r.kernel.org>
Link: http://lkml.kernel.org/r/dddbf98a2af53312e9aa73a5a2b1622fe5d6f52b.1434501121.git.luto@kernel.org
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
arch/x86/include/asm/msr.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/x86/include/asm/msr.h b/arch/x86/include/asm/msr.h
index 131eec2..54e9f08 100644
--- a/arch/x86/include/asm/msr.h
+++ b/arch/x86/include/asm/msr.h
@@ -152,6 +152,9 @@ static __always_inline unsigned long long rdtsc_ordered(void)
return rdtsc();
}
+/* Deprecated, keep it for a cycle for easier merging: */
+#define rdtscll(now) do { (now) = rdtsc_ordered(); } while (0)
+
static inline unsigned long long native_read_pmc(int counter)
{
DECLARE_ARGS(val, low, high);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists