this function is for all pnp devices. The state bits you can set are
quite powerful in the changes that they can invoke.
For instance:
you can force a query stop->stop->Start (by setting PNP_DEVICE_FAILED
and PNP_DEVICE_RESOURCE_REQUIREMENTS_CHANGED)
you can force a start -> start (by setting
PNP_DEVICE_RESOURCE_REQUIREMENTS_CHANGED)
you can force a surprise remove from the started setting by setting
PNP_DEVICE_FAILED or PNP_DEVICE_REMOVED
yes, KMDF calls this function when an error condition occurs to make
sure that the device stack is torn down. It will be called if you fail
any of the power or pnp callbacks. Power policy callbacks are failable
though and do not tear down the stack on failure. If you call
WdfDeviceSetFailed(), it will be called. You can also call
WdfDeviceSetDeviceState() to control some of the state bits being set.
d
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Michal Vodicka
Sent: Friday, February 03, 2006 12:47 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Should USB driver call IoInvalidateDeviceState
during surprise removal?
Thanks, this is what I thought. Do I understand it correctly this
function is for drivers on buses with no hot plug notification and for
the cases when driver decides to remove device on its own?
BTW, is it ever called by KMDF for USB drivers?
Best regards,
Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http://www.upek.com]
From:
xxxxx@lists.osr.com[SMTP:xxxxx@lists.osr.com
] on behalf of Doron Holan[SMTP:xxxxx@microsoft.com]
Reply To: Windows System Software Devs Interest List
Sent: Friday, February 03, 2006 9:38 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Should USB driver call
IoInvalidateDeviceState during surprise removal?
It doesn’t matter by that time for nearly all the state bits that you
would want to set in that state. You can call it if you want though,
it
will do no harm (although you may never see a query device state pnp
irp).
d
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Michal Vodicka
Sent: Friday, February 03, 2006 12:27 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] Should USB driver call IoInvalidateDeviceState during
surprise removal?
We’re trying to solve a rare problem when USB device isn’t enumerated
after ESD tests. Driver receives surprise removal IRP but not remove
IRP. I was said it should call IoInvalidateDeviceState when handling
surprise removal IRP. I don’t think so (and no DDK sample does it) but
I’d like to hear your opinion and possible consequences if it is
called.
Best regards,
Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http://www.upek.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: 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: unknown lmsubst tag argument:
‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com