Hi All,
I am relatively new to driver development and have been given the
assignment of taking over maintenance of driver written by a former
co-worker, so any help or advice anyone can give me as I bootstrap
myself would be greatly appreciated!
I am now trying to install the driver under a checked version of the XP
kernel (sp1), and keep hitting an ASSERT within a system call, which
appears to be caused by the redistributed form of the “generic.sys”
library from Oney that the co-worker included.
The interesting part of the call stack looks like:
…
nt!IoRegisterDeviceInterface
Generic!GenericRegisterInterface
Generic!InitializeGenericExtension
OurDrv!AddDevice
…
The ASSERT msg reads, “ASSERT_PASSIVE_LEVEL failed … Irql = 1”
When I follow the call stack back, I see that GenericRegisterInterface()
calls IoRegisterDeviceInterface(), after it first gets a Mutex (calls
ExAcquireFastMutex()).
The DDK explicitly says that ExAcquireFastMutex() raises IRQL to
APC_LEVEL, and also says that IoRegisterDeviceInterface() must be
called at PASSIVE_LEVEL. It seems to me that this could never work as
written, or rather never work with a checked version of the kernel with
ASSERTS turned on.
I’ve searched in the OSR lists as well as through the lists on Google,
etc. with no results. Am I missing something obvious?
Thanks in Advance, and Best Regards,
-Mike