VirtualBox

Changeset 55830 in vbox


Ignore:
Timestamp:
May 12, 2015 2:05:25 PM (10 years ago)
Author:
vboxsync
Message:

VMM/HM: hungarian.

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

Legend:

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

    r55737 r55830  
    196196{
    197197    /** The host's rflags/eflags. */
    198     RTCCUINTREG     uEflags;
     198    RTCCUINTREG     fEFlags;
    199199#if HC_ARCH_BITS == 32
    200200    uint32_t        u32Alignment0;
     
    340340
    341341    /* Paranoid: Disable interrupt as, in theory, interrupt handlers might mess with EFER. */
    342     RTCCUINTREG uEflags = ASMIntDisableFlags();
     342    RTCCUINTREG fEFlags = ASMIntDisableFlags();
    343343
    344344    /*
     
    357357        if (!pCpu->fIgnoreAMDVInUseError)
    358358        {
    359             ASMSetFlags(uEflags);
     359            ASMSetFlags(fEFlags);
    360360            return VERR_SVM_IN_USE;
    361361        }
     
    369369
    370370    /* Restore interrupts. */
    371     ASMSetFlags(uEflags);
     371    ASMSetFlags(fEFlags);
    372372
    373373    /*
     
    405405
    406406    /* Paranoid: Disable interrupts as, in theory, interrupt handlers might mess with EFER. */
    407     RTCCUINTREG uEflags = ASMIntDisableFlags();
     407    RTCCUINTREG fEFlags = ASMIntDisableFlags();
    408408
    409409    /* Turn off AMD-V in the EFER MSR. */
     
    415415
    416416    /* Restore interrupts. */
    417     ASMSetFlags(uEflags);
     417    ASMSetFlags(fEFlags);
    418418
    419419    return VINF_SUCCESS;
     
    30253025     * executing guest code.
    30263026     */
    3027     pSvmTransient->uEflags = ASMIntDisableFlags();
     3027    pSvmTransient->fEFlags = ASMIntDisableFlags();
    30283028    if (   VM_FF_IS_PENDING(pVM, VM_FF_EMT_RENDEZVOUS | VM_FF_TM_VIRTUAL_SYNC)
    30293029        || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_HM_TO_R3_MASK))
    30303030    {
    3031         ASMSetFlags(pSvmTransient->uEflags);
     3031        ASMSetFlags(pSvmTransient->fEFlags);
    30323032        VMMRZCallRing3Enable(pVCpu);
    30333033        STAM_COUNTER_INC(&pVCpu->hm.s.StatSwitchHmToR3FF);
     
    30363036    if (RTThreadPreemptIsPending(NIL_RTTHREAD))
    30373037    {
    3038         ASMSetFlags(pSvmTransient->uEflags);
     3038        ASMSetFlags(pSvmTransient->fEFlags);
    30393039        VMMRZCallRing3Enable(pVCpu);
    30403040        STAM_COUNTER_INC(&pVCpu->hm.s.StatPendingHostIrq);
     
    32393239
    32403240    Assert(!(ASMGetFlags() & X86_EFL_IF));
    3241     ASMSetFlags(pSvmTransient->uEflags);                        /* Enable interrupts. */
     3241    ASMSetFlags(pSvmTransient->fEFlags);                        /* Enable interrupts. */
    32423242    VMMRZCallRing3Enable(pVCpu);                                /* It is now safe to do longjmps to ring-3!!! */
    32433243
     
    47374737
    47384738    pVCpu->hm.s.fLoadSaveGuestXcr0 = (pCtx->cr4 & X86_CR4_OSXSAVE) && pCtx->aXcr[0] != ASMGetXcr0();
    4739     Log4(("hmR0SvmExitXsetbv: New XCR0=%#RX64 fLoadSaveGuestXcr0=%d (cr4=%RX64) rcStrict=%Rrc\n", 
     4739    Log4(("hmR0SvmExitXsetbv: New XCR0=%#RX64 fLoadSaveGuestXcr0=%d (cr4=%RX64) rcStrict=%Rrc\n",
    47404740          pCtx->aXcr[0], pVCpu->hm.s.fLoadSaveGuestXcr0, pCtx->cr4, VBOXSTRICTRC_VAL(rcStrict)));
    47414741
  • trunk/src/VBox/VMM/VMMR0/HMVMXR0.cpp

    r55815 r55830  
    214214{
    215215    /** The host's rflags/eflags. */
    216     RTCCUINTREG     uEflags;
     216    RTCCUINTREG     fEFlags;
    217217#if HC_ARCH_BITS == 32
    218218    uint32_t        u32Alignment0;
     
    775775
    776776    /* Paranoid: Disable interrupts as, in theory, interrupt handlers might mess with CR4. */
    777     RTCCUINTREG uEflags = ASMIntDisableFlags();
     777    RTCCUINTREG fEFlags = ASMIntDisableFlags();
    778778
    779779    /* Enable the VMX bit in CR4 if necessary. */
     
    792792
    793793    /* Restore interrupts. */
    794     ASMSetFlags(uEflags);
     794    ASMSetFlags(fEFlags);
    795795    return rc;
    796796}
     
    807807
    808808    /* Paranoid: Disable interrupts as, in theory, interrupts handlers might mess with CR4. */
    809     RTCCUINTREG uEflags = ASMIntDisableFlags();
     809    RTCCUINTREG fEFlags = ASMIntDisableFlags();
    810810
    811811    /* If we're for some reason not in VMX root mode, then don't leave it. */
     
    824824
    825825    /* Restore interrupts. */
    826     ASMSetFlags(uEflags);
     826    ASMSetFlags(fEFlags);
    827827    return rc;
    828828}
     
    52445244    PHMGLOBALCPUINFO pCpu;
    52455245    RTHCPHYS        HCPhysCpuPage;
    5246     RTCCUINTREG     uOldEflags;
     5246    RTCCUINTREG     fOldEFlags;
    52475247
    52485248    AssertReturn(pVM->hm.s.pfnHost32ToGuest64R0, VERR_HM_NO_32_TO_64_SWITCHER);
     
    52605260
    52615261    /* Disable interrupts. */
    5262     uOldEflags = ASMIntDisableFlags();
     5262    fOldEFlags = ASMIntDisableFlags();
    52635263
    52645264#ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
     
    52985298    {
    52995299        SUPR0ChangeCR4(0, ~X86_CR4_VMXE);
    5300         ASMSetFlags(uOldEflags);
     5300        ASMSetFlags(fOldEFlags);
    53015301        pVM->hm.s.vmx.HCPhysVmxEnableError = HCPhysCpuPage;
    53025302        return rc2;
     
    53065306    AssertRC(rc2);
    53075307    Assert(!(ASMGetFlags() & X86_EFL_IF));
    5308     ASMSetFlags(uOldEflags);
     5308    ASMSetFlags(fOldEFlags);
    53095309    return rc;
    53105310}
     
    86518651     * executing guest code.
    86528652     */
    8653     pVmxTransient->uEflags = ASMIntDisableFlags();
     8653    pVmxTransient->fEFlags = ASMIntDisableFlags();
    86548654    if (  (   VM_FF_IS_PENDING(pVM, VM_FF_EMT_RENDEZVOUS | VM_FF_TM_VIRTUAL_SYNC)
    86558655           || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_HM_TO_R3_MASK))
     
    86588658    {
    86598659        hmR0VmxClearEventVmcs(pVCpu);
    8660         ASMSetFlags(pVmxTransient->uEflags);
     8660        ASMSetFlags(pVmxTransient->fEFlags);
    86618661        VMMRZCallRing3Enable(pVCpu);
    86628662        STAM_COUNTER_INC(&pVCpu->hm.s.StatSwitchHmToR3FF);
     
    86678667    {
    86688668        hmR0VmxClearEventVmcs(pVCpu);
    8669         ASMSetFlags(pVmxTransient->uEflags);
     8669        ASMSetFlags(pVmxTransient->fEFlags);
    86708670        VMMRZCallRing3Enable(pVCpu);
    86718671        STAM_COUNTER_INC(&pVCpu->hm.s.StatPendingHostIrq);
     
    88838883    hmR0VmxCheckHostEferMsr(pVCpu);                                   /* Verify that VMRUN/VMLAUNCH didn't modify host EFER. */
    88848884#endif
    8885     ASMSetFlags(pVmxTransient->uEflags);                              /* Enable interrupts. */
     8885    ASMSetFlags(pVmxTransient->fEFlags);                              /* Enable interrupts. */
    88868886    VMMRZCallRing3Enable(pVCpu);                                      /* It is now safe to do longjmps to ring-3!!! */
    88878887
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