VirtualBox

Changeset 19611 in vbox for trunk/src/VBox


Ignore:
Timestamp:
May 12, 2009 12:23:08 PM (16 years ago)
Author:
vboxsync
Message:

Change the EM state to EMSTATE_HALTED after receiving the startup IPI.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/EM.cpp

    r19593 r19611  
    27442744 * execution loop (the outer loop being in EMR3ExecuteVM()).
    27452745 *
    2746  * @returns VBox status code. The most important ones are: VINF_EM_RESCHEDULE,
     2746 * @returns VBox status code. The most important ones are: ,
    27472747 *          VINF_EM_RESCHEDULE_REM, VINF_EM_SUSPEND, VINF_EM_RESET and VINF_EM_TERMINATE.
    27482748 *
  • trunk/src/VBox/VMM/VMM.cpp

    r19593 r19611  
    11731173
    11741174# if 1 /* If we keep the EMSTATE_WAIT_SIPI method, then move this to EM.cpp. */
     1175    EMSetState(pVCpu, EMSTATE_HALTED);
    11751176    return VINF_EM_RESCHEDULE;
    11761177# else /* And if we go the VMCPU::enmState way it can stay here. */
  • trunk/src/VBox/VMM/VMMAll/EMAll.cpp

    r19141 r19611  
    8585 *
    8686 * @returns Current status.
     87 * @param   pVCpu         The VMCPU to operate on.
    8788 */
    8889VMMDECL(EMSTATE) EMGetState(PVMCPU pVCpu)
     
    9091    return pVCpu->em.s.enmState;
    9192}
     93
     94/**
     95 * Sets the current execution manager status. (use only when you know what you're doing!)
     96 *
     97 * @param   pVCpu         The VMCPU to operate on.
     98 */
     99VMMDECL(void)    EMSetState(PVMCPU pVCpu, EMSTATE enmNewState)
     100{
     101    /* Only allowed combination: */
     102    Assert(pVCpu->em.s.enmState == EMSTATE_WAIT_SIPI && enmNewState == EMSTATE_HALTED);
     103    pVCpu->em.s.enmState = enmNewState;
     104}
     105
    92106
    93107#ifndef IN_RC
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