Usbprint.sys bug ?

Hi,
When I fail the IRP_MN_START_DEVICE when attached to a usbprint.sys device
stack as a lower filter on win2k, usbprint.sys bug checks.
The bug check happens while usbprint.sys is processing the
IRP_MN_REMOVE_DEVICE that the PnP Manager sends right after the
IRP_MN_START_DEVICE failed.
I tested this on win2k sp3 and sp4.

This problem does not occur when I fail the IRP_MN_START_DEVICE as an upper
filter and it does not exist at all on winxp.
Is anyone familiar with this problem ? Is there a fix for it that I am not
aware of ?

Thanks,
Shahar

On win2k, instead of failing start, you can always invalidate the device
state and set the PNP_DEVICE_FAILED bit in the Information field to
remove the device.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 7:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Usbprint.sys bug ?

Hi,
When I fail the IRP_MN_START_DEVICE when attached to a usbprint.sys
device
stack as a lower filter on win2k, usbprint.sys bug checks.
The bug check happens while usbprint.sys is processing the
IRP_MN_REMOVE_DEVICE that the PnP Manager sends right after the
IRP_MN_START_DEVICE failed.
I tested this on win2k sp3 and sp4.

This problem does not occur when I fail the IRP_MN_START_DEVICE as an
upper
filter and it does not exist at all on winxp.
Is anyone familiar with this problem ? Is there a fix for it that I am
not
aware of ?

Thanks,
Shahar


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

This will trigger a IRP_MN_SURPRISE_REMOVAL on the device and will work on
both win2k and winxp, but sadly this method is not good enough for my needs
since I want to totally prevent the device from functioning. The method you
are suggesting will allow the device to work in the short time between the
IRP_MN_START_DEVICE and IRP_MN_SURPRISE_REMOVAL and I can’t have that.

Do you think that the bug check that usbprint.sys generates is caused by a
bug in usbprint.sys ?

Thanks,
Shahar

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Tuesday, October 12, 2004 7:19 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

On win2k, instead of failing start, you can always invalidate the device
state and set the PNP_DEVICE_FAILED bit in the Information field to remove
the device.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 7:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Usbprint.sys bug ?

Hi,
When I fail the IRP_MN_START_DEVICE when attached to a usbprint.sys device
stack as a lower filter on win2k, usbprint.sys bug checks.
The bug check happens while usbprint.sys is processing the
IRP_MN_REMOVE_DEVICE that the PnP Manager sends right after the
IRP_MN_START_DEVICE failed.
I tested this on win2k sp3 and sp4.

This problem does not occur when I fail the IRP_MN_START_DEVICE as an upper
filter and it does not exist at all on winxp.
Is anyone familiar with this problem ? Is there a fix for it that I am not
aware of ?

Thanks,
Shahar


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com To
unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com

Yes, it probably assumes that start allocated some pointer which is
always there on the remove path b/c start always succeeded (this was
obviously fixed in later versions). After the start has been sent down
and fully completed w/success, pnp will query for the state before
allowing the device to start functioning. If the state indicates
failure, then the start, even though completed successfully, will abort.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 11:12 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

This will trigger a IRP_MN_SURPRISE_REMOVAL on the device and will work
on
both win2k and winxp, but sadly this method is not good enough for my
needs
since I want to totally prevent the device from functioning. The method
you
are suggesting will allow the device to work in the short time between
the
IRP_MN_START_DEVICE and IRP_MN_SURPRISE_REMOVAL and I can’t have that.

Do you think that the bug check that usbprint.sys generates is caused by
a
bug in usbprint.sys ?

Thanks,
Shahar

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Tuesday, October 12, 2004 7:19 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

On win2k, instead of failing start, you can always invalidate the device
state and set the PNP_DEVICE_FAILED bit in the Information field to
remove
the device.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 7:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Usbprint.sys bug ?

Hi,
When I fail the IRP_MN_START_DEVICE when attached to a usbprint.sys
device
stack as a lower filter on win2k, usbprint.sys bug checks.
The bug check happens while usbprint.sys is processing the
IRP_MN_REMOVE_DEVICE that the PnP Manager sends right after the
IRP_MN_START_DEVICE failed.
I tested this on win2k sp3 and sp4.

This problem does not occur when I fail the IRP_MN_START_DEVICE as an
upper
filter and it does not exist at all on winxp.
Is anyone familiar with this problem ? Is there a fix for it that I am
not
aware of ?

Thanks,
Shahar


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To
unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: unknown lmsubst tag argument:
‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

This is great, reporting PNP_DEVICE_FAILED in the
IRP_MN_QUERY_PNP_DEVICE_STATE is much safer than failing the
IRP_MN_START_DEVICE since I have a smaller chance of triggering a bug in one
of the drivers in the device stack. Why did you suggest to use this method
only on win2k ? Is there a reason it will not work properly on winxp ?

About the bug in usbprint.sys… Is it possible to somehow get a fixed
usbprint.sys for win2k ? (the only versions I found that does not bug check
are for winxp…)

Thanks a lot, this was very helpful.
Shahar

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Tuesday, October 12, 2004 8:29 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

Yes, it probably assumes that start allocated some pointer which is always
there on the remove path b/c start always succeeded (this was obviously
fixed in later versions). After the start has been sent down and fully
completed w/success, pnp will query for the state before allowing the device
to start functioning. If the state indicates failure, then the start, even
though completed successfully, will abort.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 11:12 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

This will trigger a IRP_MN_SURPRISE_REMOVAL on the device and will work on
both win2k and winxp, but sadly this method is not good enough for my needs
since I want to totally prevent the device from functioning. The method you
are suggesting will allow the device to work in the short time between the
IRP_MN_START_DEVICE and IRP_MN_SURPRISE_REMOVAL and I can’t have that.

Do you think that the bug check that usbprint.sys generates is caused by a
bug in usbprint.sys ?

Thanks,
Shahar

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Tuesday, October 12, 2004 7:19 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

On win2k, instead of failing start, you can always invalidate the device
state and set the PNP_DEVICE_FAILED bit in the Information field to remove
the device.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 7:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Usbprint.sys bug ?

Hi,
When I fail the IRP_MN_START_DEVICE when attached to a usbprint.sys device
stack as a lower filter on win2k, usbprint.sys bug checks.
The bug check happens while usbprint.sys is processing the
IRP_MN_REMOVE_DEVICE that the PnP Manager sends right after the
IRP_MN_START_DEVICE failed.
I tested this on win2k sp3 and sp4.

This problem does not occur when I fail the IRP_MN_START_DEVICE as an upper
filter and it does not exist at all on winxp.
Is anyone familiar with this problem ? Is there a fix for it that I am not
aware of ?

Thanks,
Shahar


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com To
unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: unknown lmsubst tag argument:
‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com To
unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com

You can file an incident report w/PSS and see if you can get a QFE. I
suggested win2k only b/c the driver works as expected on XP. If you
want to do the same thing for all OS’s, you certainly can.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 12:15 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

This is great, reporting PNP_DEVICE_FAILED in the
IRP_MN_QUERY_PNP_DEVICE_STATE is much safer than failing the
IRP_MN_START_DEVICE since I have a smaller chance of triggering a bug in
one
of the drivers in the device stack. Why did you suggest to use this
method
only on win2k ? Is there a reason it will not work properly on winxp ?

About the bug in usbprint.sys… Is it possible to somehow get a fixed
usbprint.sys for win2k ? (the only versions I found that does not bug
check
are for winxp…)

Thanks a lot, this was very helpful.
Shahar

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Tuesday, October 12, 2004 8:29 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

Yes, it probably assumes that start allocated some pointer which is
always
there on the remove path b/c start always succeeded (this was obviously
fixed in later versions). After the start has been sent down and fully
completed w/success, pnp will query for the state before allowing the
device
to start functioning. If the state indicates failure, then the start,
even
though completed successfully, will abort.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 11:12 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

This will trigger a IRP_MN_SURPRISE_REMOVAL on the device and will work
on
both win2k and winxp, but sadly this method is not good enough for my
needs
since I want to totally prevent the device from functioning. The method
you
are suggesting will allow the device to work in the short time between
the
IRP_MN_START_DEVICE and IRP_MN_SURPRISE_REMOVAL and I can’t have that.

Do you think that the bug check that usbprint.sys generates is caused by
a
bug in usbprint.sys ?

Thanks,
Shahar

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Tuesday, October 12, 2004 7:19 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Usbprint.sys bug ?

On win2k, instead of failing start, you can always invalidate the device
state and set the PNP_DEVICE_FAILED bit in the Information field to
remove
the device.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Shahar Talmi
Sent: Tuesday, October 12, 2004 7:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Usbprint.sys bug ?

Hi,
When I fail the IRP_MN_START_DEVICE when attached to a usbprint.sys
device
stack as a lower filter on win2k, usbprint.sys bug checks.
The bug check happens while usbprint.sys is processing the
IRP_MN_REMOVE_DEVICE that the PnP Manager sends right after the
IRP_MN_START_DEVICE failed.
I tested this on win2k sp3 and sp4.

This problem does not occur when I fail the IRP_MN_START_DEVICE as an
upper
filter and it does not exist at all on winxp.
Is anyone familiar with this problem ? Is there a fix for it that I am
not
aware of ?

Thanks,
Shahar


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To
unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: unknown lmsubst tag argument:
‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To
unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: unknown lmsubst tag argument:
‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com


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

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com