Re: Understanding Interrupts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



i can comment only on ur last point! :)

when handling an interrupt on a particular IRQ, that line
is disabled and ur code will not be interrupted by any interrupts
coming on that line. Other interrupts can however interrupt
execution of ur ISR. Wether these "other" interrupts are
prioritized or not i do not know....maybe somebody can throw
some light on it!!!

HTH,
mandeep

On Fri, 2004-10-01 at 17:23, mbrennan@xxxxxxxx wrote:
> Hello!
> 
> I'm reading Understanding the Linux Kernel, and I'm trying to understand
> interrupts and exceptions properly. I wonder if I have understanded this
> correctly, this is how I think it works, and I would appreciate if someone
> could confirm that its right.
> 
> So, is this correct?
> 
> Linux's interrupts are interleaved, ie. they can be nested. That must mean
> that interrupts are enabled when handling interrupts. Now the thing that
> confuses me a little is that Linux uses interrupt gates, which clears the
> IF flag, and disables interrupts. But it seems like Linux sets the IF flag
> again before the actual handler. Is this to protect the code before the
> handler from being interrupted? If so, why is this neccesary?
> 
> When interrupts are disabled by masking the maskable interrupts, does that
> mean that the CPU ignores the signal on the INTR pin. And when a IRQ is
> masked on the PIC, does that mean that the PIC doesn't send any interrupt
> to the CPU when that IRQ is raised?
> In other words, the IF flag makes the CPU ignore all maskable interrupts,
> while masking a particular IRQ, it prevents the interrupt from reaching
> the CPU.
> 
> When executing an interrupt handler, maskable interrupts are enabled but
> the IRQ of the interrupt is masked out. Other interrupts may interrupt the
> execution, but not the same as the one currently executed?
> 
> Thank you!
> 
> /Michael
> 
> --
> Kernelnewbies: Help each other learn about the Linux kernel.
> Archive:       http://mail.nl.linux.org/kernelnewbies/
> FAQ:           http://kernelnewbies.org/faq/
> 

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux