VirtualBox

Changeset 87034 in vbox


Ignore:
Timestamp:
Dec 3, 2020 12:29:59 PM (4 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
141682
Message:

VMM/HMVMXR0: Fix delivery of external interrupts when executing nested-guests. Fixes nested-guest SMP hangs described in bugref:9562#c18

File:
1 edited

Legend:

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

    r86730 r87034  
    89128912            AssertRC(rc);
    89138913
     8914            /*
     8915             * EFLAGS.IF does not control the blocking of external interrupts when
     8916             * "External interrupt exiting" set. Fixes nasty SMP hang while executing nested-guest
     8917             * VCPUs on spinlocks and aren't rescued by other VM-exits (like a preemption timer),
     8918             * see @bugref{9562#c18}.
     8919             *
     8920             * See Intel spec. 25.4.1 "Event Blocking"
     8921             */
     8922#ifdef VBOX_WITH_NESTED_HWVIRT_VMX
     8923            if (    fIsNestedGuest
     8924                &&  CPUMIsGuestVmxPinCtlsSet(pCtx, VMX_PIN_CTLS_EXT_INT_EXIT)
     8925                && !CPUMIsGuestVmxExitCtlsSet(pCtx, VMX_EXIT_CTLS_ACK_EXT_INT))
     8926            {
     8927                VBOXSTRICTRC rcStrict = IEMExecVmxVmexitExtInt(pVCpu, 0 /* uVector */, true /* fIntPending */);
     8928                Assert(rcStrict != VINF_VMX_INTERCEPT_NOT_ACTIVE);
     8929                return rcStrict;
     8930            }
     8931#endif
    89148932            if (pCtx->eflags.u32 & X86_EFL_IF)
    89158933            {
    8916 #ifdef VBOX_WITH_NESTED_HWVIRT_VMX
    8917                 if (    fIsNestedGuest
    8918                     &&  CPUMIsGuestVmxPinCtlsSet(pCtx, VMX_PIN_CTLS_EXT_INT_EXIT)
    8919                     && !CPUMIsGuestVmxExitCtlsSet(pCtx, VMX_EXIT_CTLS_ACK_EXT_INT))
    8920                 {
    8921                     VBOXSTRICTRC rcStrict = IEMExecVmxVmexitExtInt(pVCpu, 0 /* uVector */, true /* fIntPending */);
    8922                     Assert(rcStrict != VINF_VMX_INTERCEPT_NOT_ACTIVE);
    8923                     return rcStrict;
    8924                 }
    8925 #endif
    89268934                uint8_t u8Interrupt;
    89278935                rc = PDMGetInterrupt(pVCpu, &u8Interrupt);
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