WDF_STATE_NOTIFICATION_TYPE enumeration (wdfdevice.h)
[Applies to KMDF only]
Note
This enumeration is for Microsoft internal use only.
The WDF_STATE_NOTIFICATION_TYPE enumeration identifies the type of Plug and Play, power, or power policy notification that a framework-based driver will receive.
Syntax
typedef enum _WDF_STATE_NOTIFICATION_TYPE {
StateNotificationInvalid = 0x0000,
StateNotificationEnterState = 0x0001,
StateNotificationPostProcessState = 0x0002,
StateNotificationLeaveState = 0x0004,
StateNotificationAllStates = StateNotificationEnterState | StateNotificationPostProcessState | StateNotificationLeaveState
} WDF_STATE_NOTIFICATION_TYPE;
Constants
StateNotificationInvalid Value: 0x0000 For internal use only. |
StateNotificationEnterState Value: 0x0001 The driver is notified immediately before a device's Plug and Play, power, or power policy state machine enters a specified state. |
StateNotificationPostProcessState Value: 0x0002 The driver is notified immediately after a device's Plug and Play, power, or power policy state machine enters a specified state. |
StateNotificationLeaveState Value: 0x0004 The driver is notified immediately before a device's Plug and Play, power, or power policy state machine leaves a specified state. |
StateNotificationAllStates Value: StateNotificationEnterState The driver receives enter-state, postprocess-state, and leave-state notifications. |
Remarks
When the framework's state machine for a driver's device changes from state a to state b, the framework notifies the driver (if the driver registered an appropriate event callback function), in the following sequence:
- Calls state a's leave-state notification callback function.
- Calls state b's enter-state notification callback function.
- Changes the device's state from a to b.
- Calls state b's postprocess-state notification callback function.
Requirements
Requirement | Value |
---|---|
Minimum KMDF version | 1.0 |
Header | wdfdevice.h (include Wdf.h) |
See also
WDF_DEVICE_PNP_NOTIFICATION_DATA
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for