Bewerken

Delen via


Completing IRPs

"Completing an IRP" is a shorthand phrase that means "allowing all members of the driver stack to complete an I/O operation." After the IRP has been completed, the I/O manager notifies the initiating application that the requested I/O operation has finished.

When a driver has finished processing an IRP, it calls IoCompleteRequest (typically from within a DpcForIsr routine). This causes the I/O manager to determine whether any higher-level drivers have set up IoCompletion routines for the IRP. If so, each IoCompletion routine is called, in turn, until every layered driver in the chain has completed the IRP.

When all drivers have completed the IRP, the I/O manager returns status to the original requester of the operation. Note that a higher-level driver that sets up a driver-created IRP must supply an IoCompletion routine to release the IRP it created.

This section contains the following topics:

When to Complete an IRP

Completing IRPs in Dispatch Routines

Using IoCompletion Routines