VirtualBox

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


Ignore:
Timestamp:
Apr 23, 2013 3:44:47 PM (12 years ago)
Author:
vboxsync
Message:

VMM/HMVMXR0: 32-bit fixes, round 2.

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

Legend:

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

    r45682 r45684  
    39683968# error "VMX_USE_CACHED_VMCS_ACCESSES not defined when it should be!"
    39693969#endif
    3970 
    39713970#ifdef VBOX_STRICT
    39723971static bool hmR0VmxIsValidWriteField(uint32_t idxField)
     
    42874286        case VMX_VMCS64_CTRL_EPTP_FULL:
    42884287        case VMX_VMCS64_CTRL_EPTP_LIST_FULL:
    4289         /* 64-bit Read-only data fields. */
    4290         case VMX_VMCS64_EXIT_GUEST_PHYS_ADDR_FULL:
    42914288        /* 64-bit Guest-state fields. */
    42924289        case VMX_VMCS64_GUEST_VMCS_LINK_PTR_FULL:
     
    43474344        default:
    43484345        {
    4349             AssertMsgFailed(("VMXWriteVmcs64Ex: invalid field %#x (pVCpu=%p u64Val=%RX64)\n", (unsigned)idxField, pVCpu, u64Val));
     4346            AssertMsgFailed(("VMXWriteVmcs64Ex: Invalid field %#RX32 (pVCpu=%p u64Val=%#RX64)\n", idxField, pVCpu, u64Val));
    43504347            rc = VERR_INVALID_PARAMETER;
    43514348            break;
     
    43894386}
    43904387
    4391 
    4392 /**
     4388/* Enable later when the assembly code uses these as callbacks. */
     4389#if 0
     4390/*
    43934391 * Loads the VMCS write-cache into the CPU (by executing VMWRITEs).
    43944392 *
     
    44274425    }
    44284426}
     4427#endif
    44294428#endif /* HC_ARCH_BITS == 32 && defined(VBOX_ENABLE_64_BITS_GUESTS) && !defined(VBOX_WITH_HYBRID_32BIT_KERNEL) */
    44304429
     
    49494948static int hmR0VmxSaveGuestFSBaseMsr(PVMCPU pVCpu, PCPUMCTX pMixedCtx)
    49504949{
    4951     RTGCUINTREG uVal = 0;
    49524950    int rc = VINF_SUCCESS;
    49534951    if (!(pVCpu->hm.s.vmx.fUpdatedGuestState & HMVMX_UPDATED_GUEST_FS_BASE_MSR))
    49544952    {
     4953        RTGCUINTREG uVal = 0;
    49554954        rc = VMXReadVmcsGstN(VMX_VMCS_GUEST_FS_BASE, &uVal);   AssertRCReturn(rc, rc);
    49564955        pMixedCtx->fs.u64Base = uVal;
     
    49754974static int hmR0VmxSaveGuestGSBaseMsr(PVMCPU pVCpu, PCPUMCTX pMixedCtx)
    49764975{
    4977     RTGCUINTREG uVal = 0;
    49784976    int rc = VINF_SUCCESS;
    49794977    if (!(pVCpu->hm.s.vmx.fUpdatedGuestState & HMVMX_UPDATED_GUEST_GS_BASE_MSR))
    49804978    {
     4979        RTGCUINTREG uVal = 0;
    49814980        rc = VMXReadVmcsGstN(VMX_VMCS_GUEST_GS_BASE, &uVal);   AssertRCReturn(rc, rc);
    49824981        pMixedCtx->gs.u64Base = uVal;
     
    50455044static int hmR0VmxSaveGuestControlRegs(PVMCPU pVCpu, PCPUMCTX pMixedCtx)
    50465045{
    5047     RTGCUINTREG uVal    = 0;
    5048     RTGCUINTREG uShadow = 0;
    5049     int rc              = VINF_SUCCESS;
    5050 
    50515046    /* Guest CR0. Guest FPU. */
    5052     rc = hmR0VmxSaveGuestCR0(pVCpu, pMixedCtx);
     5047    int rc = hmR0VmxSaveGuestCR0(pVCpu, pMixedCtx);
    50535048
    50545049    /* Guest CR4. */
     
    50635058            && CPUMIsGuestPagingEnabledEx(pMixedCtx))
    50645059        {
     5060            RTGCUINTREG uVal = 0;
    50655061            rc = VMXReadVmcsGstN(VMX_VMCS_GUEST_CR3, &uVal);
    50665062            if (pMixedCtx->cr3 != uVal)
  • trunk/src/VBox/VMM/include/HMInternal.h

    r45637 r45684  
    4040#ifdef VBOX_WITH_OLD_VTX_CODE
    4141# define VMX_USE_CACHED_VMCS_ACCESSES
    42 #elif HC_ARCH_BITS == 32 && !defined(VBOX_WITH_HYBRID_32BIT_KERNEL)
     42#elif HC_ARCH_BITS == 32 && defined(VBOX_ENABLE_64_BITS_GUESTS) && !defined(VBOX_WITH_HYBRID_32BIT_KERNEL)
    4343# define VMX_USE_CACHED_VMCS_ACCESSES
    4444#endif
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