VirtualBox

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


Ignore:
Timestamp:
Jan 29, 2018 7:46:15 AM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
120555
Message:

VMM: Nested Hw.virt: Pick up the TSC offset from the original VMCB while applying the nested-guest TSC offset, rather
than the potentially modified VMCB.

File:
1 edited

Legend:

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

    r70781 r70782  
    29112911    Assert(CPUMIsGuestInSvmNestedHwVirtMode(pCtx));
    29122912
    2913     bool                 fParavirtTsc;
    2914     uint64_t             uTscOffset;
    2915     bool fCanUseRealTsc = TMCpuTickCanUseRealTSC(pVM, pVCpu, &uTscOffset, &fParavirtTsc);
    2916 
     2913    bool       fParavirtTsc;
     2914    uint64_t   uTscOffset;
     2915    bool const fCanUseRealTsc = TMCpuTickCanUseRealTSC(pVM, pVCpu, &uTscOffset, &fParavirtTsc);
     2916
     2917    PSVMVMCBCTRL         pVmcbNstGstCtrl  = &pVmcbNstGst->ctrl;
    29172918    PCSVMNESTEDVMCBCACHE pVmcbNstGstCache = &pVCpu->hm.s.svm.NstGstVmcbCache;
    2918     PSVMVMCBCTRL         pVmcbNstGstCtrl  = &pVmcbNstGst->ctrl;
     2919    Assert(pCtx->hwvirt.svm.fHMCachedVmcb);
    29192920
    29202921    /*
     
    29372938
    29382939    /* Apply the nested-guest VMCB's TSC offset over the guest one. */
    2939     uTscOffset = CPUMApplyNestedGuestTscOffset(pVCpu, uTscOffset);
     2940    uTscOffset = HMSvmNstGstApplyTscOffset(pVCpu, uTscOffset);
    29402941
    29412942    /* Update the nested-guest VMCB with the combined TSC offset (of guest and nested-guest). */
Note: See TracChangeset for help on using the changeset viewer.

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