Return to BSD News archive
Newsgroups: comp.os.386bsd.questions Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!agate!howland.reston.ans.net!wupost!uunet!math.fu-berlin.de!ira.uka.de!smurf.sub.org!flatlin!bad From: bad@flatlin.ka.sub.org (Christoph Badura) Subject: Re: Q:i] How get intr handlers called? Organization: Guru Systems/Funware Department Date: Wed, 14 Apr 1993 22:14:41 GMT Message-ID: <C5Hv4I.8M@flatlin.ka.sub.org> References: <52570011@hpuamsa.neth.hp.com> Lines: 21 In <52570011@hpuamsa.neth.hp.com> reink@hpuamsa.neth.hp.com (Reinier Kleipool) writes: > A question on interrupts. How does an interrupt handler gets called >when the interrupt arrives. config(8) generates a stub routine for interrupt handler. These routines are defined in /sys/compile/<machine>/vector.s with most of the code coming from the macro INTR defined in /sys/i386/isa/icu.s. The stub frobnicates some bits in the interrupt controller, pushes the unit number and calls the real interrupt routine. The address of this stub routine is installed in the processor's interrupt descriptor table after the device probes successful in isa_configure in /sys/i386/isa/isa.c. When an interrupt occurs the processor indexes the interrupt descriptor table with the interrupt vector, gets the address of the stub routine from there and calls it. -- Christoph Badura --- bad@flatlin.ka.sub.org Personally, I don't care whether someone is cool enough to quote Doug Gwyn--I only care whether Doug Gwyn is cool enough to quote. -- Larry Wall