VirtualBox

Changeset 43977 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Nov 27, 2012 4:43:29 PM (12 years ago)
Author:
vboxsync
Message:

VMM/HWVMXR0: Naming.

Location:
trunk/src/VBox/VMM
Files:
2 edited

Legend:

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

    r43961 r43977  
    282282
    283283        /* Allocate one page for the virtual APIC page for TPR caching. */
    284         rc = RTR0MemObjAllocCont(&pVCpu->hm.s.vmx.hMemObjVAPIC, PAGE_SIZE, false /* fExecutable */);
     284        rc = RTR0MemObjAllocCont(&pVCpu->hm.s.vmx.hMemObjVirtApic, PAGE_SIZE, false /* fExecutable */);
    285285        AssertRC(rc);
    286286        if (RT_FAILURE(rc))
    287287            return rc;
    288288
    289         pVCpu->hm.s.vmx.pbVAPIC     = (uint8_t *)RTR0MemObjAddress(pVCpu->hm.s.vmx.hMemObjVAPIC);
    290         pVCpu->hm.s.vmx.HCPhysVAPIC = RTR0MemObjGetPagePhysAddr(pVCpu->hm.s.vmx.hMemObjVAPIC, 0);
    291         ASMMemZeroPage(pVCpu->hm.s.vmx.pbVAPIC);
     289        pVCpu->hm.s.vmx.pbVirtApic     = (uint8_t *)RTR0MemObjAddress(pVCpu->hm.s.vmx.hMemObjVirtApic);
     290        pVCpu->hm.s.vmx.HCPhysVirtApic = RTR0MemObjGetPagePhysAddr(pVCpu->hm.s.vmx.hMemObjVirtApic, 0);
     291        ASMMemZeroPage(pVCpu->hm.s.vmx.pbVirtApic);
    292292
    293293        /* Allocate the MSR bitmap if this feature is supported. */
     
    359359            pVCpu->hm.s.vmx.HCPhysVMCS  = 0;
    360360        }
    361         if (pVCpu->hm.s.vmx.hMemObjVAPIC != NIL_RTR0MEMOBJ)
    362         {
    363             RTR0MemObjFree(pVCpu->hm.s.vmx.hMemObjVAPIC, false);
    364             pVCpu->hm.s.vmx.hMemObjVAPIC = NIL_RTR0MEMOBJ;
    365             pVCpu->hm.s.vmx.pbVAPIC      = 0;
    366             pVCpu->hm.s.vmx.HCPhysVAPIC  = 0;
     361        if (pVCpu->hm.s.vmx.hMemObjVirtApic != NIL_RTR0MEMOBJ)
     362        {
     363            RTR0MemObjFree(pVCpu->hm.s.vmx.hMemObjVirtApic, false);
     364            pVCpu->hm.s.vmx.hMemObjVirtApic = NIL_RTR0MEMOBJ;
     365            pVCpu->hm.s.vmx.pbVirtApic      = 0;
     366            pVCpu->hm.s.vmx.HCPhysVirtApic  = 0;
    367367        }
    368368        if (pVCpu->hm.s.vmx.hMemObjMsrBitmap != NIL_RTR0MEMOBJ)
     
    706706            /* Optional */
    707707            rc  = VMXWriteVmcs(VMX_VMCS32_CTRL_TPR_THRESHOLD, 0);
    708             rc |= VMXWriteVmcs64(VMX_VMCS64_CTRL_VAPIC_PAGEADDR_FULL, pVCpu->hm.s.vmx.HCPhysVAPIC);
     708            rc |= VMXWriteVmcs64(VMX_VMCS64_CTRL_VAPIC_PAGEADDR_FULL, pVCpu->hm.s.vmx.HCPhysVirtApic);
    709709
    710710            if (pVM->hm.s.vmx.msr.vmx_proc_ctls2.n.allowed1 & VMX_VMCS_CTRL_PROC_EXEC2_VIRT_APIC)
     
    28112811
    28122812    Assert(!(pVM->hm.s.vmx.msr.vmx_proc_ctls2.n.allowed1 & VMX_VMCS_CTRL_PROC_EXEC2_VIRT_APIC)
    2813            || (pVCpu->hm.s.vmx.pbVAPIC && pVM->hm.s.vmx.pbApicAccess));
     2813           || (pVCpu->hm.s.vmx.pbVirtApic && pVM->hm.s.vmx.pbApicAccess));
    28142814
    28152815    /*
     
    30663066        AssertRC(rc2);
    30673067        /* The TPR can be found at offset 0x80 in the APIC mmio page. */
    3068         pVCpu->hm.s.vmx.pbVAPIC[0x80] = u8LastTPR;
     3068        pVCpu->hm.s.vmx.pbVirtApic[0x80] = u8LastTPR;
    30693069
    30703070        /*
     
    32683268    {
    32693269        Assert(pVM->hm.s.fTPRPatchingActive);
    3270         pVCpu->hm.s.vmx.pbVAPIC[0x80] = pCtx->msrLSTAR = ASMRdMsr(MSR_K8_LSTAR);
     3270        pVCpu->hm.s.vmx.pbVirtApic[0x80] = pCtx->msrLSTAR = ASMRdMsr(MSR_K8_LSTAR);
    32713271        ASMWrMsr(MSR_K8_LSTAR, u64OldLSTAR);
    32723272    }
     
    33803380     */
    33813381    if (    fSetupTPRCaching
    3382         &&  u8LastTPR != pVCpu->hm.s.vmx.pbVAPIC[0x80])
    3383     {
    3384         rc2 = PDMApicSetTPR(pVCpu, pVCpu->hm.s.vmx.pbVAPIC[0x80]);
     3382        &&  u8LastTPR != pVCpu->hm.s.vmx.pbVirtApic[0x80])
     3383    {
     3384        rc2 = PDMApicSetTPR(pVCpu, pVCpu->hm.s.vmx.pbVirtApic[0x80]);
    33853385        AssertRC(rc2);
    33863386    }
  • trunk/src/VBox/VMM/include/HMInternal.h

    r43947 r43977  
    550550        uint64_t                    u64EntryCtls;
    551551        /** Physical address of the virtual APIC page for TPR caching. */
    552         RTHCPHYS                    HCPhysVAPIC;
     552        RTHCPHYS                    HCPhysVirtApic;
    553553        /** R0 memory object for the virtual APIC page for TPR caching. */
    554         RTR0MEMOBJ                  hMemObjVAPIC;
     554        RTR0MEMOBJ                  hMemObjVirtApic;
    555555        /** Virtual address of the virtual APIC page for TPR caching. */
    556         R0PTRTYPE(uint8_t *)        pbVAPIC;
     556        R0PTRTYPE(uint8_t *)        pbVirtApic;
    557557
    558558        /** Current CR0 mask. */
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