VirtualBox

Changeset 73245 in vbox


Ignore:
Timestamp:
Jul 19, 2018 3:18:03 PM (7 years ago)
Author:
vboxsync
Message:

VMM/CPUM: Nested VMX: bugref:9180 Report IA32_FEATURE_CONTROL.VMXON bit.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/CPUMAllMsrs.cpp

    r72866 r73245  
    240240VMM_INT_DECL(uint64_t) CPUMGetGuestIa32FeatureControl(PVMCPU pVCpu)
    241241{
    242     RT_NOREF_PV(pVCpu);
    243     return 1; /* Locked, no VT-X, no SYSENTER micromanagement. */
     242    /* Always report the MSR lock bit as set, in order to prevent guests from modifiying this MSR. */
     243    uint64_t fFeatCtl = MSR_IA32_FEATURE_CONTROL_LOCK;
     244
     245    /* Report VMX features. */
     246    if (pVCpu->CTX_SUFF(pVM)->cpum.s.GuestFeatures.fVmx)
     247        fFeatCtl |= MSR_IA32_FEATURE_CONTROL_VMXON;
     248
     249    return fFeatCtl;
    244250}
    245251
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette