It will depend on the kind of interrupt controller. But as a direct answer to the OP : > > My question is that when we mask the interrupt, do they lost or do they get > > send to processor when they unmasked back?? A masked interrupt will not get lost. Neither will it cause lost interrupts in the Kernel since the Kernel will not (should not) acknowledge masked interrupts. As soon as the interrupt is unmasked, it will cause vectoring to that ISR and then it should be processed. NOTE that some CPUs/MCUs have interrupt controllers that mask off on a priority basis. For example, the ARM family's VIC will only process interrupts that are the same or higher priority than the current priority. Lower priority interrupts in this case will not only be masked, they will NOT be processed either (even when they were unmasked, ie. Enabled). Also, with ARM (valid) interrupts that occur during an ISR are automatically pending and will be processed when the current ISR has exited and EOICR has been written. This is the default since the ARM VIC/AIC globally disables interrupts while processing an ISR. You can however explicitly re-enable global interrupts within an ISR to allow for IRQ nesting. Best Regards, Kris -----Original Message----- From: kernelnewbies-bounce@xxxxxxxxxxxx [mailto:kernelnewbies-bounce@xxxxxxxxxxxx] On Behalf Of Himanshu Chauhan Sent: Sunday, 8 February 2009 4:39 AM To: Mulyadi Santosa Cc: Shyam Burkule; Kernel Newbies Subject: Re: interrupts On Sat, 2009-02-07 at 23:58 +0700, Mulyadi Santosa wrote: > Hi > > On Sat, Feb 7, 2009 at 7:22 PM, Shyam Burkule <shyam.burkule@xxxxxxxxx> wrote: > > Hi, > > One question about Interrupt, > > > > I read in blog http://lkdp.blogspot.com/ that " When an interrupts are being > > masked, they are not lost, rather PIC remembers those and do send the > > interrupt to CPU when CPU unmasks that interrupt line." > > But in book I read that "If the kernel allows itself too much time to > > process an ISR when interrupts are disabled, it can (and will) happen that > > interrupts are lost." > > > > My question is that when we mask the interrupt, do they lost or do they get > > send to processor when they unmasked back?? > > Here's my understanding: > > when the masked interrupt line being unmasked, interrupts are fired > again. Thus, ISRs are called and then bottom halves. > > If we spent too much time in ISRs, logically we prevent the CPU that > runs the ISR to serve another interrupt, because when running an ISR > automatically interrupt line is masked. > > Furthermore, if this kind of situation happens again and again, you > can imagine that "ripple effect" will happen sooner and later: > interrupt is serviced later, another interrupt is deferred...probably > two or three...then while serving the 2nd one, one more are > pending..and so on. > > regards, > > Mulyadi. My understanding says: Given we are talking about same priority interrupts, when you are processing an interrupt and another occurs, PIC would "latch" it. And in the meantime if one more occurs, the latest would be lost. I am saying this from my observation on AT91RM9200 processor, I might be wrong though. Himanshu -- To unsubscribe from this list: send an email with "unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx Please read the FAQ at http://kernelnewbies.org/FAQ -- To unsubscribe from this list: send an email with "unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx Please read the FAQ at http://kernelnewbies.org/FAQ