]> git.karo-electronics.de Git - linux-beck.git/commit
KVM: VMX: Fix %ds/%es clobber
authorAvi Kivity <avi@redhat.com>
Sun, 13 May 2012 16:53:23 +0000 (19:53 +0300)
committerMarcelo Tosatti <mtosatti@redhat.com>
Wed, 16 May 2012 19:03:19 +0000 (16:03 -0300)
commit512d5649e8dc3ed36f2ebf0818da64a4d4c2544a
tree75fa25fcf4c7e7fc8f9fc8ab4c2aa01227ab9983
parentd54e4237bcbb400fda11c902fd538aa0b4805720
KVM: VMX: Fix %ds/%es clobber

The vmx exit code unconditionally restores %ds and %es to __USER_DS.  This
can override the user's values, since %ds and %es are not saved and restored
in x86_64 syscalls.  In practice, this isn't dangerous since nobody uses
segment registers in long mode, least of all programs that use KVM.

Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/x86/kvm/vmx.c