Within a Thread in IRQL 0 the completion routine, triggered from an IRP, for a WskSendTo call is sometimes in IRQL 2 and sometimes in IRQL 0. This seems mighty strange to me. Does anyone know if this is normal behaviour?
+2
A:
This is normal behavior.
Completion Routines may be called directly in the call to the routine or from any other context.
See the MSDN for a description of IoCompletion routines.
Christopher
2009-07-28 15:28:21
@Christopher: I owe you a beer. Because of this behaviour every context must be allocated in non-paged memory. And as IoAllocateMdl has no flag to achieve this one has to call MmBuildMdlForNonPagedPool afterwards.
Don Johe
2009-07-29 09:14:48