Changeset 80839 in vbox
- Timestamp:
- Sep 17, 2019 4:52:54 AM (5 years ago)
- svn:sync-xref-src-repo-rev:
- 133409
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/vmm/hm_vmx.h
r80767 r80839 2054 2054 /** @name VM-entry register masks. 2055 2055 * @{ */ 2056 /** CR0 bits ignored on VM-entry (ET, NW, CD and reserved bits bits 6:15, bit 17, 2057 * bits 19:28). */ 2058 #define VMX_ENTRY_CR0_IGNORE_MASK UINT64_C(0x7ffaffd0) 2059 /** DR7 bits set here are always cleared on VM-entry (bit 12, bits 14:15). */ 2060 #define VMX_ENTRY_DR7_MBZ_MASK UINT64_C(0xd000) 2061 /** DR7 bits set here are always set on VM-entry (bit 10). */ 2062 #define VMX_ENTRY_DR7_MB1_MASK UINT64_C(0x400) 2056 /** CR0 bits ignored on VM-entry while loading guest CR0 (ET, CD, NW, bits 6:15, 2057 * bit 17 and bits 19:28). */ 2058 #define VMX_ENTRY_GUEST_CR0_IGNORE_MASK UINT64_C(0x7ffaffd0) 2059 /** DR7 bits set here are always cleared on VM-entry while loading guest DR7 (bit 2060 * 12, bits 14:15). */ 2061 #define VMX_ENTRY_GUEST_DR7_MBZ_MASK UINT64_C(0xd000) 2062 /** DR7 bits set here are always set on VM-entry while loading guest DR7 (bit 2063 * 10). */ 2064 #define VMX_ENTRY_GUEST_DR7_MB1_MASK UINT64_C(0x400) 2065 /** @} */ 2066 2067 2068 /** @name VM-exit register masks. 2069 * @{ */ 2070 /** CR0 bits ignored on VM-exit while loading host CR0 (ET, CD, NW, bits 6:15, 2071 * bit 17, bits 19:28 and bits 32:63). */ 2072 #define VMX_EXIT_HOST_CR0_IGNORE_MASK UINT64_C(0xffffffff7ffaffd0) 2063 2073 /** @} */ 2064 2074 -
trunk/src/VBox/VMM/VMMAll/IEMAllCImplVmxInstr.cpp.h
r80816 r80839 1710 1710 uint64_t const uCr0Mb1 = pVCpu->cpum.GstCtx.hwvirt.vmx.Msrs.u64Cr0Fixed0; 1711 1711 uint64_t const uCr0Mb0 = pVCpu->cpum.GstCtx.hwvirt.vmx.Msrs.u64Cr0Fixed1; 1712 uint64_t const fCr0IgnMask = UINT64_C(0xffffffff1ffaffc0) | X86_CR0_ET | X86_CR0_CD | X86_CR0_NW| uCr0Mb1 | ~uCr0Mb0;1712 uint64_t const fCr0IgnMask = VMX_EXIT_HOST_CR0_IGNORE_MASK | uCr0Mb1 | ~uCr0Mb0; 1713 1713 uint64_t const uHostCr0 = pVmcs->u64HostCr0.u; 1714 1714 uint64_t const uGuestCr0 = pVCpu->cpum.GstCtx.cr0; … … 6532 6532 6533 6533 IEM_CTX_ASSERT(pVCpu, CPUMCTX_EXTRN_CR0); 6534 uint64_t const uGstCr0 = (pVmcs->u64GuestCr0.u & ~VMX_ENTRY_ CR0_IGNORE_MASK)6535 | (pVCpu->cpum.GstCtx.cr0 & VMX_ENTRY_ CR0_IGNORE_MASK);6534 uint64_t const uGstCr0 = (pVmcs->u64GuestCr0.u & ~VMX_ENTRY_GUEST_CR0_IGNORE_MASK) 6535 | (pVCpu->cpum.GstCtx.cr0 & VMX_ENTRY_GUEST_CR0_IGNORE_MASK); 6536 6536 CPUMSetGuestCR0(pVCpu, uGstCr0); 6537 6537 CPUMSetGuestCR4(pVCpu, pVmcs->u64GuestCr4.u); … … 6539 6539 6540 6540 if (pVmcs->u32EntryCtls & VMX_ENTRY_CTLS_LOAD_DEBUG) 6541 pVCpu->cpum.GstCtx.dr[7] = (pVmcs->u64GuestDr7.u & ~VMX_ENTRY_ DR7_MBZ_MASK) | VMX_ENTRY_DR7_MB1_MASK;6541 pVCpu->cpum.GstCtx.dr[7] = (pVmcs->u64GuestDr7.u & ~VMX_ENTRY_GUEST_DR7_MBZ_MASK) | VMX_ENTRY_GUEST_DR7_MB1_MASK; 6542 6542 6543 6543 pVCpu->cpum.GstCtx.SysEnter.eip = pVmcs->u64GuestSysenterEip.s.Lo;
Note:
See TracChangeset
for help on using the changeset viewer.