KMDF Device Object Creation and Initialization
Every KMDF driver that supports Plug and Play must have an EvtDriverDeviceAdd callback function. EvtDriverDeviceAdd is responsible for creating and initializing a device object and related resources. The framework calls the driver’s EvtDriverDeviceAdd callback when the system discovers a device that the driver controls.
The EvtDriverDeviceAdd callback creates a WDFDEVICE object to represent the device and performs numerous initialization tasks to provide the framework with the information that it requires to set up its own internal structures.
The EvtDriverDeviceAdd function thus proceeds as follows:
Fills in a device initialization structure with information that is used to create the device object. ...
Get Developing Drivers with the Windows® Driver Foundation now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.