USB Verify - AssertResetOrAbortPending

I am testing a windows 2000 WDM USB driver. The driver seems to work fine, but when I enable USBVerify while testing it asserts with
AssertResetOrAbortPending.

My code does issue an abort_pipe, however it waits for completion before continuing and I can’t see where I would have an overlapp. Has anyone else had this problem?

Larry


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

Hello,

For some operation you must have the rigth IRQL. Wait for completion
from IRP is only usefull at IRQL passive level. Check this.

elli


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

More info:

I am continuing to debug a problem I am seeing with my USB driver and USB Verify. I still don’t know what is going on, but I have more information.

Here is the sequence of events I see with SoftIce

App Reader thread:
Open Pipe (for read)
Read Pipe - driver does
allocates and initializes _URB_BULK_OR_INTERRUPT_TRANSFER
calls IoSetCompletionRoutine
calls IoMarkIrpPending
call IoCallDriver

App other thread:
opens device
issues ABORT pipe for read pipe
USBD completes request with SUCCESS
closes device

Driver Completion routine runs - urb status is cancelled
call IoCompleteRequest
return STATUS_MORE_PROCESSING_REQUIRED

App Reader thread:
Outstanding pipe read completes
close pipe

At this time all is well with the world! Now when I try to do it again, here’s what happens:

App Reader thread:
Open Pipe (for read)
Read Pipe - driver does
allocates and initializes _URB_BULK_OR_INTERRUPT_TRANSFER
calls IoSetCompletionRoutine
calls IoMarkIrpPending
call IoCallDriver

App other thread:
opens device
issues ABORT pipe for read pipe
USBD completes request with SUCCESS

AssertResetOrAbortPending
ASSERT(pPipeInfo->PipeFlags & pipeFlag == 0)

Now while I’m in the debugger I look at the USBD_PIPE_INFORMATION structure and the PipeFlags member is 0

Is this a bug in USBVerify? Am I looking at the wrong PipeFlags? What fo PipeFlags have to do with abort or reset anyway?

Information about the Microsoft USB stack seems to be pretty spars. In particular information about when and why a driver should call abort_pipe vs. reset_pipe vs. IoCancelIRP() is missing!

Any USB Gurus out there?

Thanks in advance

Larry

-----Original Message-----
From: Harmon, Larry CT [mailto:xxxxx@diebold.com]
Sent: Monday, August 20, 2001 9:24 AM
To: NT Developers Interest List
Subject: [ntdev] USB Verify - AssertResetOrAbortPending

I am testing a windows 2000 WDM USB driver. The driver seems to work fine, but when I enable USBVerify while testing it asserts with
AssertResetOrAbortPending.

My code does issue an abort_pipe, however it waits for completion before continuing and I can’t see where I would have an overlapp. Has anyone else had this problem?

Larry


You are currently subscribed to ntdev as: xxxxx@diebold.com
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com