Hi,
While trying to trigger a surprise removal on a device by setting the
PNP_DEVICE_FAILED bit in the IoStatus.Information of a
IRP_MN_QUERY_PNP_DEVICE_STATE request I noticed that this method does not
work on *most* child devices of USB composite devices. I am setting the bit
in a completion routine for the IRP and it does not seem any other driver
touches the IoStatus.Information before the completion ends. Composite child
devices created by usbstor.sys, usbprint.sys and usbscan.sys (those are the
drivers I tested) continue to function normally and the PnP Manager does not
remove them. Devices that are created by HPZius12.sys (this is a driver for
Dot4 USB printers from HP), however, are removed by the PnP Manager like
they should (!). I do not understand why the behavior of the PnP Manager is
different between regular devices and devices that are children of composite
devices, and I do not understand why only some drivers that have devices
that are children of composite devices do not get removed and some do. This
seems very weird and I cannot think of any logical explanation. Can anyone
shed some light on this issue ? Is this a bug in the PnP Manager for win2k
(I have no problems with winxp, all the devices get surprise removed there
like they should) ? I am running win2k with SP4 installed.
Thanks,
Shahar.