Subject: Re: Interrupt, interrupt threads, continuations, and kernel lwps
To: None <ad@NetBSD.org>
From: M. Warner Losh <imp@bsdimp.com>
List: tech-kern
Date: 02/23/2007 11:33:11
In message: <20070222205430.GA25309@hairylemon.org>
            Andrew Doran <ad@NetBSD.org> writes:
: What Jonathan is describing is roughly how FreeBSD works, I think. When the
: interrupt comes in, mi_switch() is called to dispatch it. The thread that
: was running when the interrupt came in gets kicked off the CPU.

At least until this morning... :-)

Filters were just committed to the tree that divide the ISR into two
parts.  A fast running part (the filter) that turns off the interrupt
source in the device or otherwise services the interrupt, and a
scheduled part (the ithread) that runs if the filter says to run it.
By default, ISRs with no filter always have their ithread run.  This
also eliminates the FAST_INTERRUPT special case because now all
filters are fast interrupt hanlders (in the 5.x and later sense, not
in the older 4.x and prior sense).

Warner