IRP_MN_QUERY_DEVICE_RELATIONS received twice on USB device

My driver is a virtual usb modem driver on Windows. Our USB device have two interface, one of them is used as modem interface.
My question is :
After I dial once useing my modem driver, I find I will receive a IRP_MN_QUERY_DEVICE_RELATIONS IRP and we can see following message by Windbg.

==> mfn_ProcessHardwareFailure
<== mfn_ProcessHardwareFailure

The dial up application will report an error of “ERROR 651: The modem has reported an error”.

Does anyone have experience on this problem?

In my opinion,IRP_MN_QUERY_DEVICE_RELATIONS will be received only in USB enumeration.
Why do I receive twice?

What type of relations are being sent? Are you properly sending unknown types down the stack?

D

-----Original Message-----
From: “xxxxx@gmail.com
To: “Windows System Software Devs Interest List”
Sent: 07/12/07 2:11 AM
Subject: [ntdev] IRP_MN_QUERY_DEVICE_RELATIONS received twice on USB device

My driver is a virtual usb modem driver on Windows. Our USB device have two interface, one of them is used as modem interface.
My question is :
After I dial once useing my modem driver, I find I will receive a IRP_MN_QUERY_DEVICE_RELATIONS IRP and we can see following message by Windbg.

==> mfn_ProcessHardwareFailure
<== mfn_ProcessHardwareFailure

The dial up application will report an error of “ERROR 651: The modem has reported an error”.

Does anyone have experience on this problem?


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

the relation is TargetDeviceRelatio. I have sent it down the stack.

xxxxx@gmail.com wrote:

In my opinion,IRP_MN_QUERY_DEVICE_RELATIONS will be received only in USB enumeration.
Why do I receive twice?


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

Why do you care how many times you receive it? Just process whatever pnp
requests come in, as they come in, and correctly, and don’t worry too
much about why they arrive. Better yet use KMDF and let the framework
deal with the entire pnp state machine.

TargetDeviceRelation is sent when a handle to the stack is opened, it is
not sent to enum child (which is BusDeviceRelations). This is fine.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@gmail.com
Sent: Saturday, July 14, 2007 2:21 AM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] IRP_MN_QUERY_DEVICE_RELATIONS received twice on USB
device

the relation is TargetDeviceRelatio. I have sent it down the stack.


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