Woo!
First, a big thanks to all of you who pointed out RawDeviceOK to me!
First I went nuts trying to figure out why I never got beyond BusQueryDeviceId
(a bug was causing me to return STATUS_NOT_SUPPORTED instead of STATUS_SUCCESS).
Then I went more nuts trying to figure out why my bugfix didn’t work (the
previous bug resulted in orphaned IoCreateDevice() devices, which prevented my
driver from unloading. Thus, when updating the driver, the old one remained in
memory. However, Windows made no mention of this, nor did it suggest a reboot.)
And after much grief trying to figure out why I kept getting weird bluescreens,
I realized that calling down to the next lower driver in IRP_MN_START_DEVICE is
a dumb idea if you’re the bottom of the stack…
I regret that I am once again stuck in a rut that I can’t seem to extract myself
from 
I get a START_DEVICE (as well as a number of other IRPs, like resource
requirements, etc). My virtual ports get a START_DEVICE, then immediately a
REMOVE_DEVICE and Windoze pops up a dialog asking me to help it find an
appropriate driver. However, when I cancel, I just get devices with a yellow !
by them. Device Mangler says “No driver files are required or have been
loaded for this device” on the “Driver” tab, yet the “General” tab says “The
drivers for this device are not installed.”.
Could someone please tell me WTF is going on here?
–
Real Programmers use COPY CON PROGRAM.EXE
Assuming you are using a bus driver and creating PDOs in raw-mode, you
still have to provide a function driver-like INF file. Check out this
post on the topic, it explains a lot:
http://groups.google.com/groups?q=virtual+com+Eliyas+group:microsoft.public.
development.device.drivers&hl=en&lr=&ie=UTF-8&selm=f40301c1a7cd%2458f24050%2
49ae62ecf%40tkmsftngxa02&rnum=1
–
Bill McKenzie
Compuware Corporation
Watch your IRPs/IRBs/URBs/SRBs/NDIS pkts with our free WDMSniffer tool:
http://frontline.compuware.com/nashua/patches/utility.htm
Woo!
First, a big thanks to all of you who pointed out RawDeviceOK to me!
First I went nuts trying to figure out why I never got beyond BusQueryDeviceId
(a bug was causing me to return STATUS_NOT_SUPPORTED instead of STATUS_SUCCESS).
Then I went more nuts trying to figure out why my bugfix didn’t work (the
previous bug resulted in orphaned IoCreateDevice() devices, which prevented my
driver from unloading. Thus, when updating the driver, the old one remained in
memory. However, Windows made no mention of this, nor did it suggest a reboot.)
And after much grief trying to figure out why I kept getting weird bluescreens,
I realized that calling down to the next lower driver in IRP_MN_START_DEVICE is
a dumb idea if you’re the bottom of the stack…
I regret that I am once again stuck in a rut that I can’t seem to extract myself
from 
I get a START_DEVICE (as well as a number of other IRPs, like resource
requirements, etc). My virtual ports get a START_DEVICE, then immediately a
REMOVE_DEVICE and Windoze pops up a dialog asking me to help it find an
appropriate driver. However, when I cancel, I just get devices with a yellow !
by them. Device Mangler says “No driver files are required or have been
loaded for this device” on the “Driver” tab, yet the “General” tab says “The
drivers for this device are not installed.”.
Could someone please tell me WTF is going on here?
–
Real Programmers use COPY CON PROGRAM.EXE