WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE enumeration (wdfdevice.h)
[Applies to KMDF and UMDF]
The WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE enumeration specifies when the framework calls a driver's EvtDeviceReleaseHardware callback function.
Syntax
typedef enum _WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE {
WdfReleaseHardwareOrderOnFailureInvalid = 0,
WdfReleaseHardwareOrderOnFailureEarly,
WdfReleaseHardwareOrderOnFailureAfterDescendants
} WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE, *PWDF_RELEASE_HARDWARE_ORDER_ON_FAILURE;
Constants
WdfReleaseHardwareOrderOnFailureInvalid Value: 0 Reserved for system use. |
WdfReleaseHardwareOrderOnFailureEarly Except under certain error conditions, the framework calls the driver's EvtDeviceReleaseHardware callback function after it has called the EvtDeviceReleaseHardware function for all child devices that the driver enumerates. For more information, see Remarks. |
WdfReleaseHardwareOrderOnFailureAfterDescendants The framework always calls the driver's EvtDeviceReleaseHardware callback function after it has called the EvtDeviceReleaseHardware function for all child devices that the driver enumerates. |
Remarks
The WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE enumeration is used as input to WdfDeviceInitSetReleaseHardwareOrderOnFailure.
If a driver specifies WdfReleaseHardwareOrderOnFailureEarly, then in normal device removal, the framework calls the driver's EvtDeviceReleaseHardware after it has called the EvtDeviceReleaseHardware function for all child devices that the driver enumerates. However, in the event of a device power-up or power-down failure, the framework might call the driver's EvtDeviceReleaseHardware before it has called the EvtDeviceReleaseHardware functions for all child devices.
If a driver specifies WdfReleaseHardwareOrderOnFailureAfterDescendants, then the framework waits to call the driver's EvtDeviceReleaseHardware until it has called the EvtDeviceReleaseHardware functions of the child devices.
Requirements
Requirement | Value |
---|---|
Minimum KMDF version | 1.11 |
Minimum UMDF version | 2.0 |
Header | wdfdevice.h (include Wdf.h) |