|
|
All NT drivers are identical. In other words, there is no distinction between a file system driver, a disk driver, and a host adapter driver. This allows all NT drivers to be ``stacked'' on top of each other modularly.
All driver interaction is overseen by the I/O Manager, so there is no direct communication between drivers. When an I/O request is received from a user process or a protected subsystem, it is handled as follows:
If the driver is not controlling an actual device, it should have a special entry point called a completion routine that will be called by the I/O manager when the IRP has been completed.
In some cases, a driver may have only one entry point that provides the functionality of several required entry points.
The NT kernel provides a deferred procedure call mechanism that is used to minimize the amount of time spent in an interrupt handler. When an NT driver receives an interrupt, it should immediately stop the device from interrupting, save all state information necessary to process the interrupt, and then make a deferred procedure call to a function that processes the interrupt. At some later time, the NT kernel will execute the deferred procedure call at a lower interrupt priority than the real interrupt handler.