[siemens/jailhouse] c95364: x86: Make vcpu_handle_xsetbv vmx-private

1 view
Skip to first unread message

GitHub

unread,
Aug 25, 2016, 4:50:11 PM8/25/16
to jailho...@googlegroups.com
Branch: refs/heads/next
Home: https://github.com/siemens/jailhouse
Commit: c95364b6f5e2bf2e9996ebee81e5e95b52ab4259
https://github.com/siemens/jailhouse/commit/c95364b6f5e2bf2e9996ebee81e5e95b52ab4259
Author: Jan Kiszka <jan.k...@siemens.com>
Date: 2016-08-25 (Thu, 25 Aug 2016)

Changed paths:
M hypervisor/arch/x86/include/asm/vcpu.h
M hypervisor/arch/x86/vcpu.c
M hypervisor/arch/x86/vmx.c

Log Message:
-----------
x86: Make vcpu_handle_xsetbv vmx-private

It is only used by Intel, not on AMD CPUs.

Signed-off-by: Jan Kiszka <jan.k...@siemens.com>


Commit: a116d5ff27f016ea628777a32e241584243b9dc8
https://github.com/siemens/jailhouse/commit/a116d5ff27f016ea628777a32e241584243b9dc8
Author: Jan Kiszka <jan.k...@siemens.com>
Date: 2016-08-25 (Thu, 25 Aug 2016)

Changed paths:
M hypervisor/arch/x86/include/asm/vcpu.h
M hypervisor/arch/x86/svm.c
M hypervisor/arch/x86/vmx.c

Log Message:
-----------
x86: Introduce vcpu_vendor_get_guest_cr4

This will be used to generate correct cpuid.01h results.

Signed-off-by: Jan Kiszka <jan.k...@siemens.com>


Commit: 7737e8a88c5e57379785ab39b803369a50f1b634
https://github.com/siemens/jailhouse/commit/7737e8a88c5e57379785ab39b803369a50f1b634
Author: Jan Kiszka <jan.k...@siemens.com>
Date: 2016-08-25 (Thu, 25 Aug 2016)

Changed paths:
M hypervisor/arch/x86/vmx.c

Log Message:
-----------
x86: Only execute xsetbv if actually enabled in the guest

Only perform xsetbv on behalf of the guest if it actually has it
enabled.

Fixes: 427ff407c1ae ("x86: Check for availability of xsetbv before
executing it for the guest")

Signed-off-by: Jan Kiszka <jan.k...@siemens.com>


Commit: 001b2f0c99357eb5f9054432dd9f0400304e4a3b
https://github.com/siemens/jailhouse/commit/001b2f0c99357eb5f9054432dd9f0400304e4a3b
Author: Jan Kiszka <jan.k...@siemens.com>
Date: 2016-08-25 (Thu, 25 Aug 2016)

Changed paths:
M hypervisor/arch/x86/include/asm/processor.h
M hypervisor/arch/x86/vcpu.c

Log Message:
-----------
x86: Fix cpuid.01h results regarding OSXSAVE

As we execute cpuid in the host on behalf of the guest, we have to
derive the OSXSAVE feature bit from the guest state of CR4 which
controls the availability of this while the guest is running.

Currently, if XSAVE is available and Jailhouse enables OSXSAVE for
itself in CR4, we always report it as set to the guest as well, causing
crashes or root cell applications that check for the availability via
cpuid and then run xgetbv.

Fixes: 10c6aac6eff4 ("x86: Always intercept cpuid")

Reported-by: Swaraj Dube <swara...@intel.com>
Signed-off-by: Jan Kiszka <jan.k...@siemens.com>


Compare: https://github.com/siemens/jailhouse/compare/e4afbb5581b7...001b2f0c9935
Reply all
Reply to author
Forward
0 new messages