interrupt objects in add device or prepare hardware

Should we create interrupt objects in add device or prepare hardware? what is the role of added filter resource requirements when created in prepare hardware?

xxxxx@yahoo.com wrote:

Should we create interrupt objects in add device or prepare hardware?

As the documentation states, drivers typically call WdfInterruptCreate
from their “add device” callbacks. That way, KMDF handles all of the
resource nonsense.

There are exceptions. If you have an interrupt that can wake a device,
you need to create it in “prepare hardware”. Again, that’s all
described in the documentation.

what is the role of added filter resource requirements when created in prepare hardware?

I don’t understand the question.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

Hi Tim,
Thanks for the reply. if the driver creates interrupt object in prepare hardware, it can modify the resource descriptors.

xxxxx@yahoo.com wrote:

Hi Tim,
Thanks for the reply. if the driver creates interrupt object in prepare hardware, it can modify the resource descriptors.

Where did you read that? You have to PASS the resource descriptors you
were given, because the framework can’t get them automatically. It CAN
get them automatically if you create the interrupt at “add device” time.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.