From: Jan Kiszka <[email protected]> We do not support nested virtualization, so don't make the guests believe anything different.
Signed-off-by: Jan Kiszka <[email protected]> --- hypervisor/arch/x86/vcpu.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/hypervisor/arch/x86/vcpu.c b/hypervisor/arch/x86/vcpu.c index 5210877d..43b08067 100644 --- a/hypervisor/arch/x86/vcpu.c +++ b/hypervisor/arch/x86/vcpu.c @@ -363,12 +363,17 @@ void vcpu_handle_cpuid(void) cpuid((u32 *)&guest_regs->rax, (u32 *)&guest_regs->rbx, (u32 *)&guest_regs->rcx, (u32 *)&guest_regs->rdx); if (function == 0x01) { - if (this_cell() != &root_cell) + if (this_cell() != &root_cell) { + guest_regs->rcx &= ~X86_FEATURE_VMX; guest_regs->rcx |= X86_FEATURE_HYPERVISOR; + } guest_regs->rcx &= ~X86_FEATURE_OSXSAVE; if (vcpu_vendor_get_guest_cr4() & X86_CR4_OSXSAVE) guest_regs->rcx |= X86_FEATURE_OSXSAVE; + } else if (function == 0x80000001) { + if (this_cell() != &root_cell) + guest_regs->rcx &= ~X86_FEATURE_SVM; } break; } -- 2.12.3 -- You received this message because you are subscribed to the Google Groups "Jailhouse" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
