VirtualBox

Changeset 97149 in vbox


Ignore:
Timestamp:
Oct 14, 2022 7:11:00 AM (2 years ago)
Author:
vboxsync
Message:

VMM/HMVMXR0: Nested VMX: bugref:10092 The virtual-APIC page is programmed while merging the nested-guest VMCS. If TPR shadowing is disabled, also update the virtual-APIC page address in the VMCS or when enabled, only write if the address changed.

File:
1 edited

Legend:

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

    r97148 r97149  
    916916        else
    917917        {
    918             pVmcsInfo->pbVirtApic     = &pVCpu->cpum.GstCtx.hwvirt.vmx.abVirtApicPage[0];
    919             pVmcsInfo->HCPhysVirtApic = GVMMR0ConvertGVMPtr2HCPhys(pVM, pVmcsInfo->pbVirtApic);
    920             Assert(pVmcsInfo->HCPhysVirtApic && pVmcsInfo->HCPhysVirtApic != NIL_RTHCPHYS);
     918            /* These are setup later while marging the nested-guest VMCS. */
     919            Assert(pVmcsInfo->pbVirtApic == NULL);
     920            Assert(pVmcsInfo->HCPhysVirtApic == NIL_RTHCPHYS);
    921921        }
    922922    }
     
    57165716        rc |= VMXWriteVmcs32(VMX_VMCS32_CTRL_PLE_WINDOW, cPleWindowTicks);
    57175717    }
    5718     if (u32ProcCtls & VMX_PROC_CTLS_USE_TPR_SHADOW)
    5719     {
    5720         rc |= VMXWriteVmcs32(VMX_VMCS32_CTRL_TPR_THRESHOLD, u32TprThreshold);
     5718    if (pVmcsInfoNstGst->HCPhysVirtApic != HCPhysVirtApic)
    57215719        rc |= VMXWriteVmcs64(VMX_VMCS64_CTRL_VIRT_APIC_PAGEADDR_FULL, HCPhysVirtApic);
    5722     }
     5720    rc |= VMXWriteVmcs32(VMX_VMCS32_CTRL_TPR_THRESHOLD, u32TprThreshold);
    57235721    if (u32ProcCtls2 & VMX_PROC_CTLS2_VIRT_APIC_ACCESS)
    57245722        rc |= VMXWriteVmcs64(VMX_VMCS64_CTRL_APIC_ACCESSADDR_FULL, HCPhysApicAccess);
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