Driver verifier Query

Hi,

I am using Driver verifier to test my driver.

the driver passes all the tests on its on but when i start up the user space application that communicates with it the system crashes (what i mean by on its own is when it isnt communicating with user space) note it still does proccessing since its job is to capture packets as such it does not need to communicate with user mode in order to do some work. the only thing that changes when a user space application communicates with the driver is that it starts sending data to that application.

Thanks. !!

Well you have a bug in the handling of packets up to user space. A lot
of verifier is checking the handling of IRP’s so until you get an
application involved you are not doing a lot of testing of your driver.

Don Burn (MVP, Windows DKD)
Windows Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr

xxxxx@hotmail.com” wrote in
message news:xxxxx@ntdev:

> Hi,
>
> I am using Driver verifier to test my driver.
>
> the driver passes all the tests on its on but when i start up the user space application that communicates with it the system crashes (what i mean by on its own is when it isnt communicating with user space) note it still does proccessing since its job is to capture packets as such it does not need to communicate with user mode in order to do some work. the only thing that changes when a user space application communicates with the driver is that it starts sending data to that application.
>
> Thanks. !!

You have a bug. Post the output of !analyze -v from the debugger.

-scott


Scott Noone
Consulting Associate and Chief System Problem Analyst
OSR Open Systems Resources, Inc.
http://www.osronline.com

wrote in message news:xxxxx@ntdev…

Hi,

I am using Driver verifier to test my driver.

the driver passes all the tests on its on but when i start up the user
space application that communicates with it the system crashes (what i
mean by on its own is when it isnt communicating with user space) note it
still does proccessing since its job is to capture packets as such it does
not need to communicate with user mode in order to do some work. the only
thing that changes when a user space application communicates with the
driver is that it starts sending data to that application.

Thanks. !!

The following STOP message is displayed once i restart the vm

BCCode : c9 BCP1 : 00000226 BCP2 : F7788592 BCP3 : 00000000
BCP4 : 00000000

How about the !analyze -v.

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@hotmail.com
Sent: Tuesday, February 08, 2011 10:21 AM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] Driver verifier Query

The following STOP message is displayed once i restart the vm

BCCode : c9 BCP1 : 00000226 BCP2 : F7788592 BCP3 : 00000000
BCP4 : 00000000


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

>An IRP dispatch handler has returned without passing down or completing
this IRP, or someone forgot to return STATUS_PENDING. (IRP specified.)

(from: http://msdn.microsoft.com/en-us/library/ff560205(v=vs.85).aspx)

You might want to see what !irp 0xF7788952 reports.

What does your control routine look like?

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@hotmail.com
Sent: Tuesday, February 08, 2011 10:21 AM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] Driver verifier Query

The following STOP message is displayed once i restart the vm

BCCode : c9 BCP1 : 00000226 BCP2 : F7788592 BCP3 : 00000000
BCP4 : 00000000


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Note that !analyze -v doesn’t do anything after stops caused by the
verifier.

However, this one is a dead giveaway: your code is wrong. You failed to do
an IoCompleteRequest but did not return STATUS_PENDING and/or you did not
pass the IRP down to a lower level driver. If you *did* pass it down to a
lower-level driver and returned the status that driver returned to you, then
*that* driver is wrong, but in my experience, it usually means *your* code
is wrong.

And yes, when this happens, the driver does give the illusion of working
correctly, most of the time. But you have violated protocol, and the fact
that it is working this week might change with a new release of the OS, a
service pack, or a hotfix. And there is always the potential that there is
a deep and serious problem that has thus far escaped notice.

As already requested, you have to show the code.
joe

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Martin O’Brien
Sent: Tuesday, February 08, 2011 10:51 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Driver verifier Query

An IRP dispatch handler has returned without passing down or completing
this IRP, or someone forgot to return STATUS_PENDING. (IRP specified.)

(from: http://msdn.microsoft.com/en-us/library/ff560205(v=vs.85).aspx)

You might want to see what !irp 0xF7788952 reports.

What does your control routine look like?

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@hotmail.com
Sent: Tuesday, February 08, 2011 10:21 AM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] Driver verifier Query

The following STOP message is displayed once i restart the vm

BCCode : c9 BCP1 : 00000226 BCP2 : F7788592 BCP3 : 00000000
BCP4 : 00000000


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Actually, the driver gives the illusion of working (“passes all the tests on
its own”) but it is not actually correct (this is a bit like the complaint I
frequently get: “The Debug library is full of bugs because it keeps giving
me assertion errors when I run, but if I run with the release library I
don’t get those errors. When is Microsoft going to fix all those bugs in
the debug library?” to which the reply is “Your code is wrong. The debug
library detects errors the release library doesn’t, and they are your
errors. So you have to fix them.” The same is true of the Driver Verifier:
if it reports an error, your code is wrong. Fix it.)

Note also that the system does not “crash”; what you get is a driver
verifier stop, caused by an error in your driver. If you have the debugger
attached, then you have the option of stopping or continuing. But it still
means your driver has an error and you have to fix it. I responded to a
later post with more detail but you have to show the code.
joe

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@hotmail.com
Sent: Tuesday, February 08, 2011 9:12 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Driver verifier Query

Hi,

I am using Driver verifier to test my driver.

the driver passes all the tests on its on but when i start up the user
space application that communicates with it the system crashes (what i
mean by on its own is when it isnt communicating with user space) note it
still does proccessing since its job is to capture packets as such it does
not need to communicate with user mode in order to do some work. the only
thing that changes when a user space application communicates with the
driver is that it starts sending data to that application.

Thanks. !!


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Hi I solved the problem.

Basicly there was a condition in the IRP that handles cleanups that if it is true it will return pending but it wasnt setting it to pending hence the error … (very stupid mistake)

Sorry for wasting your time.