STATUS_UNSUCCESFULL is a generic error code, which is seldom returned. Most of the status codes are named
excelent, and their name is self explanatory. It would be a titanic work to document every possible status code
which can be returned as a result of an IO request sent down to a device stack, and tell you exactly why this happend, even if we take in account drivers which are bundled with the operating system. But dont forget that the IO manager has a layered design, and any 3rd party filter device in the device stack can fail a IO request operation for whatever reason, and return a phantasmagoric error code.
Frankly , it doesnt worth the effort.
Dan
----- Original Message -----
From: Chris Dore
To: NT Developers Interest List
Sent: Tuesday, July 09, 2002 6:02 PM
Subject: [ntdev] Re: Sending IOCTLs Down
If the return values had a meaning or error messages were logged somewhere it would be much better. If the returns/status’ were well documented it would probably save a lot of time. Seems wasteful for people to dig around figuring out what went wrong when the original designers could probably document everything they need to know in order to determine what exactly failed. STATUS_UNSUCCESSFUL doesn’t say much when there is nothing telling me what error conditions generate it.
Just my nickels worth, Chris
----- Original Message -----
From: Dan Partelly
To: NT Developers Interest List
Sent: Monday, July 08, 2002 5:40 PM
Subject: [ntdev] Re: Sending IOCTLs Down
Debug it . Make good use of OS symbols, dont just keep them on your harddrive.
Ciao , Dan
----- Original Message -----
From: Chris Dore
To: NT Developers Interest List
Sent: Tuesday, July 09, 2002 12:02 AM
Subject: [ntdev] Re: Sending IOCTLs Down
Is there a way I can determine why the USB stack is returning STATUS_UNSUCCESSFUL? I need more information as to why it is failing.
Thanks, Chris
----- Original Message -----
From: Chris Dore
To: NT Developers Interest List
Sent: Friday, July 05, 2002 10:08 AM
Subject: [ntdev] Re: Sending IOCTLs Down
Here’s the problem I am experiencing with this routine:
IoCallDriver returns pending, the wait occurs, then IOStatus.Status = -1073741823
I’m not sure why the USB stack is returning a status like this. I use this routine for a bunch of different URBs however this “error” always happens on the same one, and only if more than one of my USB devices is plugged in. To add to things, if you step through the code or add debugging messages between the call to IoCallDriver and the wait, the problem disappears. That why I asked about when IoCallDriver returns and what causes the event to signal. I thought that maybe the event was being signaled before the USB stack has finished.
Also, it is does not always happen. Sometimes it gets through with a status of 0. If you change the IOStatus.Status value from the -1073741823 to 0 (from windbg) and let the routine succeed. All goes well as if it had been 0 in the first place. I tried running a free build of my driver and the exact same results appear. I also added verifier to the USB stack drivers to see if anything would happen, but nothing has so far.
Is this a valid status value defined in the USB headers that I don’t know of?
Any thoughts/suggestions?
Thanks, Chris
----- Original Message -----
From: Chris Dore
To: NT Developers Interest List
Sent: Thursday, July 04, 2002 4:17 PM
Subject: [ntdev] Sending IOCTLs Down
In the following procedure:
NTSTATUS CallUSBD (IN PDEVICE_OBJECT pDevObject, IN PURB pUrb)
{
NTSTATUS Status;
PIRP pIrp;
KEVENT Event;
IO_STATUS_BLOCK IOStatus;
PIO_STACK_LOCATION pNextStack;
PAGED_CODE ();
KeInitializeEvent(&Event, NotificationEvent, FALSE);
pIrp = IoBuildDeviceIoControlRequest (IOCTL_INTERNAL_USB_SUBMIT_URB, pDevObject,
NULL, 0, NULL, 0, TRUE, &Event, &IOStatus);
// Call the class driver to perform the operation. If the returned status
// is PENDING, wait for the request to complete.
pNextStack = IoGetNextIrpStackLocation (pIrp);
pNextStack->Parameters.Others.Argument1 = pUrb;
Status = IoCallDriver (pDevObject, pIrp);
if (Status == STATUS_PENDING)
KeWaitForSingleObject (&Event, Suspended, KernelMode, FALSE, NULL);
else
IOStatus.Status = Status;
// USBD maps the error code for us
Status = IOStatus.Status;
return (Status);
}
When does IoCallDriver return? Upon completion of the IRP?
Further more, when does the Event get signaled? Upon Completion or after all completion routines have executed?
I couldn’t seem to find concrete answers in the DDK (if I missed something please let me know where it is in the DDK).
The DDK says the event is signaled when the lower driver(s) have completed the requested operation. But to what extent does completed mean? Just the call to IoCompleteRequest or also the completion of the completion routines.
Thanks, Chris
You are currently subscribed to ntdev as: xxxxx@connecttech.com
To unsubscribe send a blank email to %%email.unsub%%
You are currently subscribed to ntdev as: xxxxx@connecttech.com
To unsubscribe send a blank email to %%email.unsub%%
You are currently subscribed to ntdev as: xxxxx@rdsor.ro
To unsubscribe send a blank email to %%email.unsub%%
You are currently subscribed to ntdev as: xxxxx@connecttech.com
To unsubscribe send a blank email to %%email.unsub%%
You are currently subscribed to ntdev as: xxxxx@rdsor.ro
To unsubscribe send a blank email to %%email.unsub%%