VirtualBox

Changeset 78771 in vbox for trunk/src


Ignore:
Timestamp:
May 27, 2019 4:05:29 AM (6 years ago)
Author:
vboxsync
Message:

VMM/IEM: Nested VMX: bugref:9180 LMSW nit.

File:
1 edited

Legend:

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

    r78719 r78771  
    30503050                                              uint8_t cbInstr)
    30513051{
    3052     if (CPUMIsGuestVmxLmswInterceptSet(pVCpu, &pVCpu->cpum.GstCtx, *pu16NewMsw))
     3052    Assert(pu16NewMsw);
     3053
     3054    uint16_t const uNewMsw = *pu16NewMsw;
     3055    if (CPUMIsGuestVmxLmswInterceptSet(pVCpu, &pVCpu->cpum.GstCtx, uNewMsw))
    30533056    {
    30543057        Log2(("lmsw: Guest intercept -> VM-exit\n"));
     
    30693072                         | RT_BF_MAKE(VMX_BF_EXIT_QUAL_CRX_ACCESS,    VMX_EXIT_QUAL_CRX_ACCESS_LMSW)
    30703073                         | RT_BF_MAKE(VMX_BF_EXIT_QUAL_CRX_LMSW_OP,   fMemOperand)
    3071                          | RT_BF_MAKE(VMX_BF_EXIT_QUAL_CRX_LMSW_DATA, *pu16NewMsw);
     3074                         | RT_BF_MAKE(VMX_BF_EXIT_QUAL_CRX_LMSW_DATA, uNewMsw);
    30723075
    30733076        return iemVmxVmexitInstrWithInfo(pVCpu, &ExitInfo);
     
    30843087    uint32_t const fGstHostMask     = pVmcs->u64Cr0Mask.u;
    30853088    uint32_t const fGstHostLmswMask = fGstHostMask & (X86_CR0_PE | X86_CR0_MP | X86_CR0_EM | X86_CR0_TS);
    3086     *pu16NewMsw = (uGuestCr0 & fGstHostLmswMask) | (*pu16NewMsw & ~fGstHostLmswMask);
     3089    *pu16NewMsw = (uGuestCr0 & fGstHostLmswMask) | (uNewMsw & ~fGstHostLmswMask);
    30873090
    30883091    return VINF_VMX_INTERCEPT_NOT_ACTIVE;
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