VirtualBox

Ignore:
Timestamp:
Jul 15, 2014 3:43:30 PM (10 years ago)
Author:
vboxsync
Message:

VMM: Fix NMI handling.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/recompiler/VBoxRecompiler.c

    r51326 r52041  
    22372237    }
    22382238
     2239    /* Update the inhibit NMI mask. */
     2240    pVM->rem.s.Env.hflags2 &= ~HF2_NMI_MASK;
     2241    if (VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_INHIBIT_NMIS))
     2242        pVM->rem.s.Env.hflags2 |= HF2_NMI_MASK;
     2243
    22392244    /*
    22402245     * Sync the A20 gate.
     
    27232728        Log(("Clearing VMCPU_FF_INHIBIT_INTERRUPTS at %RGv - successor %RGv (REM#2)\n", (RTGCPTR)pCtx->rip, EMGetInhibitInterruptsPC(pVCpu)));
    27242729        VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_INHIBIT_INTERRUPTS);
     2730    }
     2731
     2732    /* Inhibit NMI flag. */
     2733    if (pVM->rem.s.Env.hflags2 & HF2_NMI_MASK)
     2734    {
     2735        Log(("Settings VMCPU_FF_INHIBIT_NMIS at %RGv (REM)\n", (RTGCPTR)pCtx->rip));
     2736        VMCPU_FF_SET(pVCpu, VMCPU_FF_INHIBIT_NMIS);
     2737    }
     2738    else if (VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_INHIBIT_NMIS))
     2739    {
     2740        Log(("Clearing VMCPU_FF_INHIBIT_NMIS at %RGv (REM)\n", (RTGCPTR)pCtx->rip));
     2741        VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_INHIBIT_NMIS);
    27252742    }
    27262743
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