Changeset 65794 in vbox for trunk/src/VBox
- Timestamp:
- Feb 15, 2017 8:39:16 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR3/EM.cpp
r65650 r65794 478 478 VMMR3_INT_DECL(void) EMR3ResetCpu(PVMCPU pVCpu) 479 479 { 480 /* Reset scheduling state. */ 480 481 pVCpu->em.s.fForceRAW = false; 482 VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_UNHALT); 481 483 482 484 /* VMR3ResetFF may return VINF_EM_RESET or VINF_EM_SUSPEND, so transition … … 1343 1345 */ 1344 1346 if ( VM_FF_IS_PENDING(pVM, VM_FF_ALL_REM_MASK) 1345 || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_ALL_REM_MASK ))1347 || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_ALL_REM_MASK & ~VMCPU_FF_UNHALT)) 1346 1348 return VINF_SUCCESS; 1347 1349 } … … 1898 1900 } 1899 1901 1900 /*1901 * Forced unhalting of EMT.1902 */1903 if (VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_UNHALT))1904 {1905 VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_UNHALT);1906 if (rc == VINF_EM_HALT)1907 rc = VINF_EM_RESCHEDULE;1908 else1909 {1910 rc2 = VINF_EM_RESCHEDULE;1911 UPDATE_RC();1912 }1913 }1914 1915 1902 /* check that we got them all */ 1916 Assert(!(VMCPU_FF_NORMAL_PRIORITY_MASK & ~ (VMCPU_FF_REQUEST | VMCPU_FF_UNHALT)));1903 Assert(!(VMCPU_FF_NORMAL_PRIORITY_MASK & ~VMCPU_FF_REQUEST)); 1917 1904 } 1918 1905 … … 2211 2198 && rc != VINF_EM_OFF 2212 2199 && ( VM_FF_IS_PENDING(pVM, VM_FF_ALL_REM_MASK) 2213 || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_ALL_REM_MASK )))2200 || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_ALL_REM_MASK & ~VMCPU_FF_UNHALT))) 2214 2201 { 2215 2202 rc = emR3ForcedActions(pVM, pVCpu, rc); … … 2486 2473 VBOXVMM_EM_STATE_CHANGED(pVCpu, enmOldState, enmNewState, rc); 2487 2474 2488 /* Clear MWait flags . */2475 /* Clear MWait flags and the unhalt FF. */ 2489 2476 if ( enmOldState == EMSTATE_HALTED 2490 && (pVCpu->em.s.MWait.fWait & EMMWAIT_FLAG_ACTIVE) 2477 && ( (pVCpu->em.s.MWait.fWait & EMMWAIT_FLAG_ACTIVE) 2478 || VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_UNHALT)) 2491 2479 && ( enmNewState == EMSTATE_RAW 2492 2480 || enmNewState == EMSTATE_HM … … 2498 2486 || enmNewState == EMSTATE_DEBUG_GUEST_REM) ) 2499 2487 { 2500 LogFlow(("EMR3ExecuteVM: Clearing MWAIT\n")); 2501 pVCpu->em.s.MWait.fWait &= ~(EMMWAIT_FLAG_ACTIVE | EMMWAIT_FLAG_BREAKIRQIF0); 2488 if (pVCpu->em.s.MWait.fWait & EMMWAIT_FLAG_ACTIVE) 2489 { 2490 LogFlow(("EMR3ExecuteVM: Clearing MWAIT\n")); 2491 pVCpu->em.s.MWait.fWait &= ~(EMMWAIT_FLAG_ACTIVE | EMMWAIT_FLAG_BREAKIRQIF0); 2492 } 2493 if (VMCPU_FF_IS_PENDING(pVCpu, VMCPU_FF_UNHALT)) 2494 { 2495 LogFlow(("EMR3ExecuteVM: Clearing UNHALT\n")); 2496 VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_UNHALT); 2497 } 2502 2498 } 2503 2499 }
Note:
See TracChangeset
for help on using the changeset viewer.