The thing with the WDM IRP preprocess callback is that you don’t get a
WDFREQUEST, only a PIRP. If you need to probe/lock memory via a
WDFMEMORY, there is no place to cleanly hang the WDFMEMORY off of. if
you need this for some other purpose, it is probably the function for
you.
d
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Dan Kyler
Sent: Wednesday, February 28, 2007 10:58 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] EvtIoInCallerContext callback: totally useless?
And to complete this thread…
It appears that WdfDeviceInitAssignWdmIrpPreprocessCallback can be used
to
the same effect without the arbitrary IRQL restrictions.
I find something new in Kmdf every day ![:slight_smile: :slight_smile:](/images/emoji/twitter/slight_smile.png?v=12)
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Dan Kyler
Sent: Wednesday, February 28, 2007 11:44 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] EvtIoInCallerContext callback: totally useless?
Even better…
Thanks,
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Wednesday, February 28, 2007 11:36 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] EvtIoInCallerContext callback: totally useless?
EvtIoInCallerContext is only called for requests managed by a WDFQUEUE.
That
means read/write/ioctl/internal ioctl. Pnp/power/wmi/etc do not flow
through this function
d
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Dan Kyler
Sent: Wednesday, February 28, 2007 10:06 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] EvtIoInCallerContext callback: totally useless?
Related question:
If I set an EvtIoInCallerContext callback for the FDO of a bus driver,
and
all my explicit accesses to that FDO are at PASSIVE_LEVEL, are there any
circumstances (Power, PNP, etc.) where my EvtIoInCallerContext callback
could be called at greater than PASSIVE_LEVEL?
If not, then I think I can get this to work.
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Wednesday, February 28, 2007 10:13 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] EvtIoInCallerContext callback: totally useless?
What do you need to do in EvtIoInCallerContext that must be done at IRQL
PASSIVE_LEVEL? The point of this function is to probe and lock UM
buffers in the right context, all other processing can be done in the
arbitrary context of the WDFQUEUE. If you are getting I/O at APC or
dispatch level, that means a KM component is sending you the i/o, so no
probe/lock is required.
With that said, there was talk in the team of removing the IRQL
restriction
on WdfDeviceEnqueueRequest, but that doesn’t help you now
d
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Dan Kyler
Sent: Wednesday, February 28, 2007 8:31 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] EvtIoInCallerContext callback: totally useless?
The documentation for EvtIoInCallerContext says it is called in the
thread
context of the caller, at PASSIVE_LEVEL.
Being naturally skeptical of these conflicting claims, I tested it, and
found that, as one might expect, it is called in the thread context and
at
the IRQL of the caller of IoCallDriver.
I can certainly deal with that–it’s obviously no different than the
context
and IRQL for the dispatch routine in a WDM driver. The problem is that
WdfDeviceEnqueueRequest can only be called at PASSIVE_LEVEL. So when
you
get a request in EvtIoInCallerContext at APC_LEVEL or DISPATCH_LEVEL,
what
the heck are you supposed to do with it? It seems the only option is to
complete it, which naturally means your driver doesn’t work.
Thanks,
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
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
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
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
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
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