// usbpmapi.h
EVT_USBPM_EVENT_CALLBACK EvtUsbpmEventCallback;
VOID EvtUsbpmEventCallback(
[In] PUSBPM_EVENT_CALLBACK_PARAMS Params
)
{...}
View the official Windows Driver Kit DDI referenceNo description available.
Sends notifications about hub arrival/removal and connector state changes.
Params [In]A pointer to the caller-supplied USBPM_EVENT_CALLBACK_PARAMS structure that the client driver fills with event-specific data.
//Declaration
EVT_USBPM_EVENT_CALLBACK EvtUsbpmEventCallback;
// Definition
VOID EvtUsbpmEventCallback
(
PUSBPM_EVENT_CALLBACK_PARAMS Params
)
{...}
The client driver registers its implementation of this callback function by setting the appropriate member of USBPM_CLIENT_CONFIG and then calling UsbPm_Register. Policy Manager can invoke the client driver's implementation before [UsbPm_Register] returns.
To stop Policy Manager from invoking the callback function, the client driver must call UsbPm_Deregister.
Callback function calls are serialized. Only one call is active at a time.