Subject: Re: [PATCH 2/7] [POWERPC] Fix QEIC->MPIC cascading

From: Benjamin Herrenschmidt <[email-masked]>
Date: Tue, 02 Oct 2007 09:14:21 +1000

On Tue, 2007-09-25 at 18:34 +0400, Anton Vorontsov wrote:
> set_irq_chained_handler overwrites MPIC's handle_irq function
> (handle_fasteoi_irq) thus MPIC never gets eoi event from the
> cascaded IRQ. This situation hangs MPIC on MPC8568E.
> 
> Patch adds flow level "end" handler to the MPIC, and QEIC calls
> it when QEIC's interrupt processing finished.
> 
> Signed-off-by: Anton Vorontsov <[email-masked]>

Not sure if I already NAKed it on the list, so if I didn't here's it :-)

The proper way of doing that is to have the cascade handler perform the
EOI call to mpic. Look at how it's done for i8259 mpic cascade handlers.

Basically, when doing a cascade nowadays, you can either just do a
normal request_irq() of the cascade, in which case your handler don't
have to care about the parent controller at all, but you get various
limitations and/or overhead from being a full blown interrupt handler,
or you can use the chained handler mechanism which is a "shortcut" but
implies that your cascade handler "knows" what needs to be done to the
parent (and thus is specific to the combination parent/child).

Cheers,
Ben.