Hardware notifications

Overview of the Hardware notifications technology.

To develop Hardware notifications, you need these headers:

For the programming guide, see Hardware notifications.

Functions

Title Description
HwNProcessAddDevicePostDeviceCreate function Creates I/O queues. It should be called after the client driver’s EVT_WDF_DRIVER_DEVICE_ADD callback function is invoked and the device object has been created.
HwNProcessAddDevicePreDeviceCreate function Supplies the device prepare/release and entry/exit callbacks to the Windows Driver Foundation (WDF) for transitioning the device into different states.
HwNRegisterClient function Registers the hardware notification client driver and its callback functions with the class extension.
HwNUnregisterClient function Unregisters the hardware notification client driver and its callback functions with the class extension. This function should be invoked when the client driver is unloaded.

Callback functions

Title Description
HWN_CLIENT_GET_STATE function Implemented by the client driver to get hardware notification component state. It is invoked when a user requests status information.
HWN_CLIENT_INITIALIZE_DEVICE function Implemented by the client driver and is invoked as a result of a call to EVT_WDF_DEVICE_PREPARE_HARDWARE.
HWN_CLIENT_QUERY_DEVICE_INFORMATION function Implemented by the client driver to retrieve hardware notification component attributes.
HWN_CLIENT_SET_STATE function Implemented by the client driver to set hardware notification component state. It is invoked when a user wants to change the state of a driver.
HWN_CLIENT_START_DEVICE function Implemented by the client driver to start the hardware notification component. It is invoked as a result of a call to EVT_WDF_DEVICE_D0_ENTRY.
HWN_CLIENT_STOP_DEVICE function Implemented by the client driver TO start the hardware notification component. It is invoked as a result of a call to EVT_WDF_DEVICE_D0_EXIT.
HWN_CLIENT_UNINITIALIZE_DEVICE function Implemented by the client driver and invoked as invoked as a result of a call to EVT_WDF_DEVICE_RELEASE_HARDWARE. This callback function uninitializes the hardware notification component.

Structures

Title Description
_CLIENT_DEVICE_INFORMATION structure The CLIENT_DEVICE_INFORMATION structure is used by the hardware notification callback HWN_CLIENT_QUERY_DEVICE_INFORMATION to return the total number of hardware notifications that the client device driver provides.
_HWN_CLIENT_REGISTRATION_PACKET structure Hardware Notification client driver registration packet that is passed to the class extension when a client driver is registered. Contains version information and client driver callback functions.

Enumerations

Title Description
_HWN_CLX_EXPORT_INDEX Enumeration Defines the position for each of the Hardware Notification exports in the export table.