I wrote a USB driver that does the following to send/receive packets on
the USB :
(1) I allocate an IRP using IoAllocateIrp
(2) I set the completion routine using IoSetCompletionRoutine
(3) Call IoCallDriver to transmit the IRP to the USBD.sys driver
(Microsoft USB host controller driver)
(4) Then I do a WaitForSingleObject on an Event that will be set by the
completion routine when the IRP will have been processed by the
USBD.sys.
(5) When the event is signalled, WaitForSingleObject returns and I clean
the IRP by doing a IoFreeIrp.
Then here is what happens once in a while : The Completion Routines gets
called several times in a raw by Windows for the very *same* IRP !!!!
Is this a normal behavior ? What should I do to tell Windows that the
IRP is complete and it's no use calling the Completion Routine anymore ?
Any help is welcome !!!
ThanX !
Etienne
I don't suppose you are assuming that each call to IoAllocateIrp
produces a new and different IRP value? For example if you call
IoAllocateIrp, IoFreeIrp, and IoAllocateIrp again, it is very likely,
especially on an otherwise idle system, that you will get the same
value for PIRP from each call to IoAllocateIrp.
On Tue, 10 Jul 2001 11:46:22 GMT, "E. Kuntzel" <ekun...@free.fr>
wrote:
=
Mark Roddy
WindowsNT Windows2000 Consultant
Hollis Technology Solutions
http://www.hollistech.com
ma...@hollistech.com
603-321 1032
-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
-----== Over 80,000 Newsgroups - 16 Different Servers! =-----