Skip to contentSkip to conversation

x86, msr, remove unused native_read_tscp()

PATCH In review Prarit Bhargava 3 participants 3 messages Mar 22, 2016 – Mar 23, 2016 x86

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86, msr, remove unused native_read_tscp()

After e76b027 ("x86,vdso: Use LSL unconditionally for vgetcpu") native_read_tscp() is unused in the kernel. The function can be removed like native_read_tsc() was.

[prarit@prarit linux]$ git grep native_read_tscp arch/x86/include/asm/msr.h:45:static inline unsigned long long native_read_tscp(unsigned int *aux)

---
 arch/x86/include/asm/msr.h |    8 --------
 1 file changed, 8 deletions(-)
arch/x86/include/asm/msr.h +0 -8
index 93fb7c1..7a79ee2 100644
@@ -42,14 +42,6 @@ struct saved_msrs {
 	struct saved_msr *array;
 };
 
-static inline unsigned long long native_read_tscp(unsigned int *aux)
-{
-	unsigned long low, high;
-	asm volatile(".byte 0x0f,0x01,0xf9"
-		     : "=a" (low), "=d" (high), "=c" (*aux));
-	return low | ((u64)high << 32);
-}
-
 /*
  * both i386 and x86_64 returns 64-bit value in edx:eax, but gcc's "A"
  * constraint has different meanings. For i386, "A" means exactly
Signature · 1 line
1.7.9.3
#1 lore raw
Quoted 3 lines · Prarit Bhargava

After e76b027 ("x86,vdso: Use LSL unconditionally for vgetcpu") native_read_tscp() is unused in the kernel. The function can be removed like native_read_tsc() was.

Fine with me. We can always re-add it if we need it in the future.

--Andy

#2 lore raw

[tip:x86/urgent] x86/msr: Remove unused native_read_tscp()

In reply to Prarit Bhargava
x86/msr: Remove unused native_read_tscp()
Commit-ID:  9da77666d6975219281fd400eb9608a047337414
Gitweb:     http://git.kernel.org/tip/9da77666d6975219281fd400eb9608a047337414
Author:     Prarit Bhargava <[email protected]>
AuthorDate: Tue, 22 Mar 2016 19:06:08 -0400
Committer:  Thomas Gleixner <[email protected]>
CommitDate: Wed, 23 Mar 2016 12:34:17 +0100

x86/msr: Remove unused native_read_tscp()

After e76b027 ("x86,vdso: Use LSL unconditionally for vgetcpu") native_read_tscp() is unused in the kernel. The function can be removed like native_read_tsc() was.

---
 arch/x86/include/asm/msr.h | 8 --------
 1 file changed, 8 deletions(-)
arch/x86/include/asm/msr.h +0 -8
index 93fb7c1..7a79ee2 100644
@@ -42,14 +42,6 @@ struct saved_msrs {
 	struct saved_msr *array;
 };
 
-static inline unsigned long long native_read_tscp(unsigned int *aux)
-{
-	unsigned long low, high;
-	asm volatile(".byte 0x0f,0x01,0xf9"
-		     : "=a" (low), "=d" (high), "=c" (*aux));
-	return low | ((u64)high << 32);
-}
-
 /*
  * both i386 and x86_64 returns 64-bit value in edx:eax, but gcc's "A"
  * constraint has different meanings. For i386, "A" means exactly