]> git.baikalelectronics.ru Git - kernel.git/commit
hypervisor/x86/xen: Unset X86_BUG_SYSRET_SS_ATTRS on Xen PV guests
authorBoris Ostrovsky <boris.ostrovsky@oracle.com>
Mon, 4 May 2015 15:02:15 +0000 (11:02 -0400)
committerDavid Vrabel <david.vrabel@citrix.com>
Tue, 5 May 2015 17:27:43 +0000 (18:27 +0100)
commit901c5f41904047e3c8dcf6f1432efe03a3d00faf
treeca33c267fb1d81c9f2207e29be17fc4f82235407
parent98c6bf38fb4739b59e3ef17925ddaebebee9a39e
hypervisor/x86/xen: Unset X86_BUG_SYSRET_SS_ATTRS on Xen PV guests

Commit 3c69f9a0f91a ("x86_64, asm: Work around AMD SYSRET SS descriptor
attribute issue") makes AMD processors set SS to __KERNEL_DS in
__switch_to() to deal with cases when SS is NULL.

This breaks Xen PV guests who do not want to load SS with__KERNEL_DS.

Since the problem that the commit is trying to address would have to be
fixed in the hypervisor (if it in fact exists under Xen) there is no
reason to set X86_BUG_SYSRET_SS_ATTRS flag for PV VPCUs here.

This can be easily achieved by adding x86_hyper_xen_hvm.set_cpu_features
op which will clear this flag. (And since this structure is no longer
HVM-specific we should do some renaming).

Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Reported-by: Sander Eikelenboom <linux@eikelenboom.it>
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
arch/x86/include/asm/hypervisor.h
arch/x86/kernel/cpu/hypervisor.c
arch/x86/xen/enlighten.c