lkml.org 
[lkml]   [2014]   [Oct]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v2 8/8 only] x86,vdso: Use LSL unconditionally for vgetcpu
Date
Andy Lutomirski <luto@amacapital.net> writes:

> LSL is faster than RDTSCP and works everywhere; there's no need to
> switch between them depending on CPU.

Yes it should have been done like this from day 1.

> diff --git a/arch/x86/vdso/vclock_gettime.c b/arch/x86/vdso/vclock_gettime.c
> index 9793322751e0..d14bb8faad16 100644
> --- a/arch/x86/vdso/vclock_gettime.c
> +++ b/arch/x86/vdso/vclock_gettime.c
> @@ -11,6 +11,9 @@
> * Check with readelf after changing.
> */
>
> +/* Disable static_cpu_has debugging; it doesn't work in the vDSO */
> +#undef CONFIG_X86_DEBUG_STATIC_CPU_HAS
> +
> #include <uapi/linux/time.h>
> #include <asm/vgtod.h>
> #include <asm/hpet.h>
> diff --git a/arch/x86/vdso/vgetcpu.c b/arch/x86/vdso/vgetcpu.c
> index add1d98d2477..fd8470c98ab5 100644
> --- a/arch/x86/vdso/vgetcpu.c
> +++ b/arch/x86/vdso/vgetcpu.c
> @@ -5,10 +5,12 @@
> * Fast user context implementation of getcpu()
> */
>
> +/* Disable static_cpu_has debugging; it doesn't work in the vDSO */
> +#undef CONFIG_X86_DEBUG_STATIC_CPU_HAS


These two hunks are unrelated?

-Andi

--
ak@linux.intel.com -- Speaking for myself only


\
 
 \ /
  Last update: 2014-10-27 13:01    [W:0.034 / U:0.736 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site