Partager via


PMExt_PMBeforeNewSystemState (Compact 2013)

3/26/2014

This function is called by Power Manager to indicate that the system is about to enter a new power state.

Syntax

VOID PMExt_PMBeforeNewSystemState{
    DWORD dwExtContext,
    LPCTSTR lpNewStateName,
    DWORD dwFlags
};

Parameters

  • dwExtContext
    [in] Context value returned after PME initialization by PMExt_Init.
  • lpNewStateName
    [in] Names the pending system state. If this parameter is not NULL, the dwFlags parameter is ignored.
  • dwFlags
    [in] Optional. If lpNewStateName is NULL, dwFlags is used to name the pending system state by using the POWER_STATE_XXX flags defined in the Pm.h header file.

Return Value

None.

Remarks

This callback is used by Power Manager to indicate that the system is about to enter a new power state. The Power Management Extension (PME) can act upon this call perform any desired actions before the system transitions to the specified power state.

Warning

Power Management Extensions execute within the context of the core Power Manager, and can have a significant effect on overall system performance and security. Errors in a PME can block the core Power Manager thread indefinitely; this can cause the system to stop responding. Performance issues in a PME can harm overall system performance. Security vulnerabilities in a PME can increase a system's vulnerability to malicious attacks.

Requirements

Header

Pmext.h

See Also

Reference

Power Management Functions