17#if defined(EVENT_TRACING)
18#include "DevicePwrReqStateMachine.tmh"
152 ASSERTMSG(
"The device power requirement state machine queue is full\n",
163 "WDFDEVICE 0x%p !devobj 0x%p current device power requirement state"
164 " %!FxDevicePwrRequirementStates! dropping event "
165 "%!FxDevicePwrRequirementEvents! because of a closed queue",
174 "The device power requirement state machine queue is closed\n",
202 if (FxWaitLockInternal::IsLockAcquired(
status)) {
248 pThis = PkgPnp->m_PowerPolicyMachine.m_Owner->
336 newState =
entry->TargetStates[
i].DprState;
349 "WDFDEVICE 0x%p !devobj 0x%p device power requirement state "
350 "%!FxDevicePwrRequirementStates! dropping event "
351 "%!FxDevicePwrRequirementEvents!",
361 while (newState !=
DprMax) {
366 "WDFDEVICE 0x%p !devobj 0x%p entering device power requirement "
367 "state %!FxDevicePwrRequirementStates! from "
368 "%!FxDevicePwrRequirementStates!",
390 newState =
entry->StateFunc(
this);
406 This->m_PoxInterface->PkgPnp()->PowerPolicyProcessEvent(
417 This->m_PoxInterface->PkgPnp()->PowerPolicyProcessEvent(
428 This->m_PoxInterface->PoxReportDevicePoweredOn();
WDFDEVICE __inline GetHandle(VOID)
MdDeviceObject __inline GetDeviceObject(VOID)
static FxDevicePwrRequirementStates PowerRequiredDx(__in FxDevicePwrRequirementMachine *This)
FxDevicePwrRequirementMachineStateHistory m_States
static const FxDevicePwrRequirementTargetState m_UnregisteredStates[]
static const FxDevicePwrRequirementTargetState m_DevicePowerRequiredD0States[]
static FxDevicePwrRequirementStates PowerNotRequiredD0(__in FxDevicePwrRequirementMachine *This)
static FxDevicePwrRequirementStates ReportingDevicePowerAvailable(__in FxDevicePwrRequirementMachine *This)
FxDevicePwrRequirementMachine(__in FxPoxInterface *PoxInterface)
static const FxDevicePwrRequirementTargetState m_DevicePowerNotRequiredDxStates[]
static const FxDevicePwrRequirementTargetState m_DevicePowerRequiredDxStates[]
static const FxDevicePwrRequirementTargetState m_WaitingForDevicePowerRequiredD0States[]
FxDevicePwrRequirementEvents m_Queue[FxDevicePwrRequirementEventQueueDepth]
static VOID _ProcessEventInner(__inout FxPkgPnp *PkgPnp, __inout FxPostProcessInfo *Info, __in PVOID WorkerContext)
VOID ProcessEvent(__in FxDevicePwrRequirementEvents Event)
VOID ProcessEventInner(__inout FxPostProcessInfo *Info)
static const FxDevicePwrRequirementTargetState m_DevicePowerNotRequiredD0States[]
FxPoxInterface * m_PoxInterface
static const FxDevicePwrRequirementStateTable m_StateTable[]
__inline PFX_DRIVER_GLOBALS GetDriverGlobals(VOID)
__inline CfxDevice * GetDevice(VOID)
FxDevicePwrRequirementMachine * m_DevicePowerRequirementMachine
#define TRACINGPNPPOWERSTATES
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
FxDevicePwrRequirementStates
@ DprDevicePowerRequiredD0
@ DprDevicePowerNotRequiredD0
@ DprDevicePowerNotRequiredDx
@ DprWaitingForDevicePowerRequiredD0
@ DprDevicePowerRequiredDx
@ DprReportingDevicePowerAvailable
FxDevicePwrRequirementEvents
@ DprEventDeviceReturnedToD0
@ DprEventDeviceGoingToDx
@ DprEventPoxDoesNotRequirePower
@ DprEventRegisteredWithPox
@ DprEventUnregisteredWithPox
@ DprEventPoxRequiresPower
const UCHAR FxDevicePwrRequirementEventQueueDepth
@ PwrPolDevicePowerNotRequired
@ PwrPolDevicePowerRequired
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define __analysis_assume(expr)
#define ASSERTMSG(msg, exp)
#define UNREFERENCED_PARAMETER(P)
#define TRACE_LEVEL_INFORMATION
UCHAR IncrementHistoryIndex(VOID)
FxWaitLockInternal m_StateMachineLock
BOOLEAN IsClosedLocked(VOID)
VOID GetFinishedState(__inout FxPostProcessInfo *Info)
#define RtlZeroMemory(Destination, Length)
UCHAR History[FxDevicePwrRequirementEventQueueDepth]
_Must_inspect_result_ _In_ WDFCHILDLIST _In_ PWDF_CHILD_LIST_ITERATOR _Out_ WDFDEVICE _Inout_opt_ PWDF_CHILD_RETRIEVE_INFO Info
_Must_inspect_result_ _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFWAITLOCK * Lock