On Wed, 20 Mar 2002, hzeng wrote: > Maybe the question I ask is too stupid. But please excuse me to waste your time. > When I read the kernel , I wonder what is the way the interrupt passed by. For example > when a ethernet card emit a interrupt, the irq request is send from the net card to the IPC, > and then the IPC send the interrupt to the cpu, and then the cpu answer the interrupt and send > the ack message to IPC, and then ? What is the right way? If every interrupt must be send to the > IPC firstly? > I am not very clearly about the process. Please cc to me, as I cannot subscribe the mail successly. Yes you're right, to put things simplistically, the network card triggers an interrupt, which is one of the "lines" connected to the PIC and then the PIC triggers the appropriate line on the CPU, which then stops everything its doing and jumps to the appropriate interrupt service routine (ISR) vector/address. Note that the interrupt handler and vectors have to be all programmed (done in the kernel), so the CPU doesn't know anything about them so essentially it doesn't know what to do with them by default. The CPU keeps track of its ISRs via the interrupt descriptor table (IDT) which has a "listing" of all ISR addresses. Also note that there are some interrupts which don't go via the PIC, such as the non maskable interrupt (NMI), system management interrupt (SMI) and on systems with an advanced programmable interrupt controller (APIC) there are inter processor interrupts (IPI) which are used on most x86 multi-cpu systems. hope that helps, Zwane -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/