Hi all,
Though this is not a question specific to File Systems area, i have come across the word APCs while reading stuff (articles) on File systems.
What i understand is that there are three types of APCs:
- User mode APC
- Kernel Mode APC
- Special Kernel mode APC
Can somebody explain them in detail, how they differ & their usage scenarios?
Thank you very much.
Tushar.
Hello,
Explaining APC dispatching on a forum is not a very good idea because there is rigorous information that needs to be explained, not in 20 or 30 lines, so I would advise you to get a book on driver development and read carefully.
Even in MSDN is quite enough infomation, but you have to read between lines.
Here are some hints for reading.
Scheduling, Thread Context, and IRQL
http://msdn2.microsoft.com/en-us/library/ms810029.aspx
(Pay attention to Interrupt Request Levels, Processor-specific and Thread-specific IRQLs, Asynchronous Procedure Calls)
Asynchronous Procedure Calls
http://msdn2.microsoft.com/en-us/library/aa490221.aspx
all three subtopics
How Completion Processing Is Performed
http://msdn2.microsoft.com/en-us/library/ms790765.aspx
(example of usage in the system)
Hope it helps
-bg
> What i understand is that there are three types of APCs:
- User mode APC
KernelRoutine called immediately when you’re on PASSIVE_LEVEL and not in the
critical region.
NormalRoutine is invoked in user mode by ntdll!KiUserApcDispatcher on the next
return from kernel to user.
- Kernel Mode APC
Same as the above, but NormalRoutine is called in kernel mode on PASSIVE_LEVEL.
- Special Kernel mode APC
Has no NormalRoutine. KernelRoutine is invoked when you’re on PASSIVE_LEVEL
even if you’re in the critical region.
IopCompleteRequest is IIRC the only special kernel APC.
–
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com