Messages in this thread |  | | Date | Sat, 11 Apr 2015 01:10:13 +0200 | From | Andi Kleen <> | Subject | Re: [PATCH 5/8] x86: Make old K8 swapgs workaround conditional |
| |
On Sat, Apr 11, 2015 at 12:01:10AM +0200, Borislav Petkov wrote: > > diff --git a/arch/x86/kernel/cpu/amd.c b/arch/x86/kernel/cpu/amd.c > > index a220239..e7f5667 100644 > > --- a/arch/x86/kernel/cpu/amd.c > > +++ b/arch/x86/kernel/cpu/amd.c > > @@ -551,6 +551,9 @@ static void init_amd_k8(struct cpuinfo_x86 *c) > > if ((level >= 0x0f48 && level < 0x0f50) || level >= 0x0f58) > > set_cpu_cap(c, X86_FEATURE_REP_GOOD); > > > > + /* Early steppings needed a mfence on swapgs. */ > > + set_cpu_cap(c, X86_BUG_SWAPGS_MFENCE); > > set_cpu_bug() > > and this should not be set on all K8 but for the early steppings only > which need it.
I don't know which one, but I don't think it really matters.
-Andi
|  |