Fundamentally not understanding the nature of IRPs and threads

These following may sound stupid to you seasoned veterans out there, but I’m
having issues with it all. Essentially, I think I misunderstand how IRPs
work in the context of different threads.

Am I correct in saying that if I set a completion routine for an IRP (that
can be synchronous) and use events to wait for completion of that IRP in my
dispatch routine, other IRPs for other threads that come through this
dispatch routine will still be processed concurrently and that the wait will
only suspend the calling thread, and not hold up the whole system? Or will
all other IRPs directed to the dispatch routine simply be queued by the I/O
Manager until the wait is satisfied and the dispatcher is free to continue
processing them?

Ivan Lewis-Coker
Software Developer
AppSense Technologies
Europa Way
Bird Hall Lane
Cheadle Heath
Stockport
SK3 0WY

Tel: +44 (0) 161 610 4200
Fax:+44 (0) 161 610 4242

email: xxxxx@appsense.net
www: http://www.appsense.net

CONFIDENTIAL
The contents of this email and any attachments may be
confidential. It is intended for the named recipient(s).
If you are not the named recipient please notify the sender
immediately and do not disclose the contents to any other
person or make any copies.

> dispatch routine, other IRPs for other threads that come through this

dispatch routine will still be processed concurrently and that the wait
will
only suspend the calling thread, and not hold up the whole system?

Yes.

Or will
all other IRPs directed to the dispatch routine simply be queued by the
I/O
Manager until the wait is satisfied and the dispatcher is free to continue
processing them?

Use StartIo routine if you want this non-reentrant behaviour. Dispatch
routines
do not provide this.
Note that you cannot wait in StartIo routine - it is called on
DISPATCH_LEVEL.

Max