interrupt handlers in -current
John Baldwin
jhb at FreeBSD.org
Fri Jun 6 09:39:46 PDT 2003
On 06-Jun-2003 M. Warner Losh wrote:
> In message: <XFMail.20030606002657.dmlb at dmlb.org>
> Duncan Barclay <dmlb at dmlb.org> writes:
>:
>: On 05-Jun-2003 M. Warner Losh wrote:
>: > In message: <XFMail.20030605220236.dmlb at dmlb.org>
>: > Duncan Barclay <dmlb at dmlb.org> writes:
>: >: This is more of a confirmation of my understanding than anything else.
>: >: In -current, should an interrupt thread be created you set up an interrupt
>: >: handler? If so, then I'd better check my code because I haven't got one!
>: >
>: > No. Just because we handle interrupts in a thread doesn't mean client
>: > devices need to create a thread. The thread is creted automatically
>: > and the routine passed to bus_setup_intr() is then called when an
>: > interrupt happens.
>:
>: Rereading what I wrote, I might have mistyped and asked the wrong question.
>:
>: I think what you saying is that bus_setup_intr() doesn't create the thread,
>: (in the sense of it appear in ps -ax?)
>: but a thread is created automatically when the first interrupt occurs?
>
> The thread is created right away. However, if this interrupt is
> shared with another device, you'll see seomthing like:
>
> root 23 0.0 0.0 0 12 ?? WL 11:35AM 0:04.24 (irq10: cbb0 cbb1++)
>
> which says taht cbb0 and cbb1 (and others) share irq10.
The thread is created right away, but I think KSE broke ps/top in
that they don't show new processes anymore that haven't run yet. This
is definitely a bug in the kernel.
--
John Baldwin <jhb at FreeBSD.org> <>< http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve!" - http://www.FreeBSD.org/
More information about the freebsd-hackers
mailing list