Re: Strange 8255 behavior

From: Segher Boessenkool <segher_at_kernel.crashing.org>
Date: Sun, 10 Jun 2018 08:43:27 -0500
Message-ID: <20180610134327.GA27520@gate.crashing.org>
On Sun, Jun 10, 2018 at 07:50:42AM -0400, Jeff Laughton wrote:
> 
> >On 10/06/2018 10:57, André Fachat wrote:
> >
> >>[...] (like I guess clearing interrupt flags by just reading the 
> >>flags....).
> 
> I believe clearing interrupts by reading the flags is actually a
> feature. It leads to a shorter Interrupt Service Routine because you
> don't have to reset that flag explicitly. But yes you have to pay
> attention or it'll bite you.  :-(

Unless you have a slightly more complex system where you do not handle
all interrupt at once (say, you want to have some priority system for
the interrupt handling), in which case you then need to double-buffer
the status bits.  Which makes the interrupt routines longer and slower :-/


Segher
Received on 2018-06-10 16:02:02

Archive generated by hypermail 2.2.0.