diff options
author | Andy Lutomirski <luto@amacapital.net> | 2014-10-30 17:58:01 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2014-11-03 07:41:53 -0500 |
commit | e76b027e6408f5570dc940b731ec9ae870c6188a (patch) | |
tree | d94287f98ee13c7e2fedd4890499f178079ce6ab /arch/x86/kernel/cpu/common.c | |
parent | a92f101bc99d17b75021cf29f18cc57f39a37d1f (diff) |
x86,vdso: Use LSL unconditionally for vgetcpu
LSL is faster than RDTSCP and works everywhere; there's no need to
switch between them depending on CPU.
Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Cc: Andi Kleen <andi@firstfloor.org>
Link: http://lkml.kernel.org/r/72f73d5ec4514e02bba345b9759177ef03742efb.1414706021.git.luto@amacapital.net
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/cpu/common.c')
-rw-r--r-- | arch/x86/kernel/cpu/common.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c index 4b4f78c9ba19..175372b854be 100644 --- a/arch/x86/kernel/cpu/common.c +++ b/arch/x86/kernel/cpu/common.c | |||
@@ -956,14 +956,6 @@ static void identify_cpu(struct cpuinfo_x86 *c) | |||
956 | } | 956 | } |
957 | 957 | ||
958 | #ifdef CONFIG_X86_64 | 958 | #ifdef CONFIG_X86_64 |
959 | static void vgetcpu_set_mode(void) | ||
960 | { | ||
961 | if (cpu_has(&boot_cpu_data, X86_FEATURE_RDTSCP)) | ||
962 | vgetcpu_mode = VGETCPU_RDTSCP; | ||
963 | else | ||
964 | vgetcpu_mode = VGETCPU_LSL; | ||
965 | } | ||
966 | |||
967 | #ifdef CONFIG_IA32_EMULATION | 959 | #ifdef CONFIG_IA32_EMULATION |
968 | /* May not be __init: called during resume */ | 960 | /* May not be __init: called during resume */ |
969 | static void syscall32_cpu_init(void) | 961 | static void syscall32_cpu_init(void) |
@@ -1006,8 +998,6 @@ void __init identify_boot_cpu(void) | |||
1006 | #ifdef CONFIG_X86_32 | 998 | #ifdef CONFIG_X86_32 |
1007 | sysenter_setup(); | 999 | sysenter_setup(); |
1008 | enable_sep_cpu(); | 1000 | enable_sep_cpu(); |
1009 | #else | ||
1010 | vgetcpu_set_mode(); | ||
1011 | #endif | 1001 | #endif |
1012 | cpu_detect_tlb(&boot_cpu_data); | 1002 | cpu_detect_tlb(&boot_cpu_data); |
1013 | } | 1003 | } |