VirtualBox

Changeset 42343 in vbox for trunk/src/VBox/VMM/VMMR0


Ignore:
Timestamp:
Jul 24, 2012 10:33:39 AM (12 years ago)
Author:
vboxsync
Message:

VMM/HWVMXR0: cCachedMSRs are for guest MSRs during the world switch. Clarified some comments as well.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp

    r42186 r42343  
    13841384        rc = VMXWriteVMCS(VMX_VMCS_CTRL_EXIT_MSR_LOAD_COUNT, idxMsr);
    13851385        AssertRC(rc);
    1386 
    1387         pVCpu->hwaccm.s.vmx.cCachedMSRs = idxMsr;
    13881386#endif /* VBOX_WITH_AUTO_MSR_LOAD_RESTORE */
    13891387
     
    21202118    /*
    21212119     * Store all guest MSRs in the VM-entry load area, so they will be loaded
    2122      * during the world switch.
     2120     * during VM-entry and restored into the VM-exit store area during VM-exit.
    21232121     */
    21242122    PVMXMSR pMsr = (PVMXMSR)pVCpu->hwaccm.s.vmx.pGuestMSR;
     
    21772175    }
    21782176
    2179     /*
    2180      * The number of host MSRs saved must be identical to the number of guest MSRs loaded.
    2181      * It's not a VT-x requirement but how it's practically used here.
    2182      */
    2183     Assert(pVCpu->hwaccm.s.vmx.cCachedMSRs == idxMsr);
     2177    pVCpu->hwaccm.s.vmx.cCachedMSRs = idxMsr;
    21842178
    21852179    rc = VMXWriteVMCS(VMX_VMCS_CTRL_ENTRY_MSR_LOAD_COUNT, idxMsr);
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