KMDF and DO_POWER_PAGEABLE

Hi,

I already sent this as DDK feedback but got no reply, so I thought maybe
someone here knows the answer.

The KMDF docs specify that the EvtDeviceD0Entry and EvtDeviceD0Exit
routines get called at IRQL=PASSIVE. nothing more is mentioned.
The osrusbfx2 sample however has the following comment about those
functions:

This function runs at PASSIVE_LEVEL, though it is generally not paged. A

driver can optionally make this function pageable if DO_POWER_PAGABLE is
set.

Even if DO_POWER_PAGABLE isn’t set, this function still runs at

PASSIVE_LEVEL. In this case, though, the function absolutely must not do

anything that will cause a page fault.

I did a search for DO_POWER_PAGABLE in the KMDF docs but it is nowhere
mentioned.
Does anyone know which is correct? The comment or the docs?

Kind regards,
Bruno van Dooren
xxxxx@hotmail.com
Remove only “_nos_pam”

We already revised the docs based on your question, sorry you didn’t get
feedback on that.

If you are power pageable, you are allowed to cause page faults in your
power and power policy callbacks. If you are not power pagable, you
cannot cause page faults. Either way, you are called at passive level
for all callbacks.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Bruno van Dooren
Sent: Sunday, March 19, 2006 2:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF and DO_POWER_PAGEABLE

Hi,

I already sent this as DDK feedback but got no reply, so I thought maybe

someone here knows the answer.

The KMDF docs specify that the EvtDeviceD0Entry and EvtDeviceD0Exit
routines get called at IRQL=PASSIVE. nothing more is mentioned.
The osrusbfx2 sample however has the following comment about those
functions:

This function runs at PASSIVE_LEVEL, though it is generally not paged. A

driver can optionally make this function pageable if DO_POWER_PAGABLE is

set.

Even if DO_POWER_PAGABLE isn’t set, this function still runs at

PASSIVE_LEVEL. In this case, though, the function absolutely must not do

anything that will cause a page fault.

I did a search for DO_POWER_PAGABLE in the KMDF docs but it is nowhere
mentioned.
Does anyone know which is correct? The comment or the docs?

Kind regards,
Bruno van Dooren
xxxxx@hotmail.com
Remove only “_nos_pam”


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer