From: Bill McKenzie on
>One issue is obviously IRP stack allocations

Well actually I would suspect the bus would adjust the PDOs' stack sizes in
that case.

Your right all around...I wasn't thinking about I/O having to go to the
underlying bus. I was thinking about requests actually specific to that
stack.

Bill M.

"Mark Roddy" <markr(a)hollistech.com> wrote in message
news:ueychI5pHHA.1148(a)TK2MSFTNGP06.phx.gbl...
> Bill McKenzie wrote:
>> This newsreader is f'ing up. The following sentence:
>>
>> "In the case where you have to ebus driver's PDOs
>> and its FDO, you are best off using IRP_MN_QUERY_INTERFACE and setting up
>> explicit pointer sharing between the two."
>>
>> originally read:
>>
>> "In the case where you have to communicate between the bus driver's PDOs
>> and its FDO, you are best off using IRP_MN_QUERY_INTERFACE and setting up
>> explicit pointer sharing between the two."
>>
>> Bill M.
>
>
> The design that forwards PDO requests to the parent FDO is fairly common.
> Offhand I am not sure I know why a function pointer interface is
> necessarily better. One issue is obviously IRP stack allocations, however
> whichever mechanism you use, an interface or forwarding the IRP to the
> parent FDO, you have to deal with that problem.
>
> WdfPdoGetParent gets a wdf handle to the parent FDO.
>>
>> "Bill McKenzie" <bkmckenzie(a)sbcglobal.net> wrote in message
>> news:OBsnHB4pHHA.3736(a)TK2MSFTNGP03.phx.gbl...
>>> First of all...the PDO is the bottom of the stack, you can't go lower.
>>> The FDO for the bus driver is not in the same stack as the bus driver
>>> created PDOs. They are the bottom of their own driver stack. In
>>> general, the PDO should handle it's own requests and you shouldn't have
>>> to pass these on to the bus driver's FDO. However, there are
>>> exceptions, IRP_MN_WAIT_WAKE is not the least of these. In the case
>>> where you have to ebus driver's PDOs and its FDO, you are best off using
>>> IRP_MN_QUERY_INTERFACE and setting up explicit pointer sharing between
>>> the two. There is an example of how to use this in the WDK KMDF toaster
>>> bus driver sample.
>>>
>>> Bill M.
>>>
>>> <casyang(a)gmail.com> wrote in message
>>> news:1181047984.159030.204310(a)a26g2000pre.googlegroups.com...
>>>> Dear all:
>>>>
>>>> For filter drivers, KMDF automatically forwards the request to the
>>>> default I/O target (the next lower driver).
>>>>
>>>> How to do this in PDO? Is there any option to do this?
>>>>
>>>> I write two drivers: one for a bus driver to enumerate child device,
>>>> and another is for child device. I want to forward all child device
>>>> FDO request to bus driver FDO. So I need the function mentioned in
>>>> subject.
>>>>
>>>> Thanks.
>>>>
>>>> Casper
>>>>
>>>
>>