On Sun, May 26, 2013 at 11:09:03AM +0000, Orit Moskovich wrote: > Can a filter routine preempt another filter routine? And can an interrupt > thread (or a filter routine) preempt another ithread?
Filter handler borrows the context from the thread executed at the time of the interrupt. At least on x86 (i.e. i386 and amd64) interrupt handlers are executed with the interrupts disabled. So the filter cannot interrupt another filter. Interrupt threads are executed with the interrupts enabled. So if an interrupt is delivered to the CPU while the CPU executed the ithread, the filter 'preempts' the ithread by executing in its context. For the same reason, if the interrupt delivered causes a higher-priority thread become ready to run, then the new runnable thread could preempt the interrupt thread according to the priority, affinity and other factors considered by a scheduler.
pgpsGRsiThClG.pgp
Description: PGP signature