Level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-07-29 Thread Sergey Temerkhanov
Hi, all! I'm currently in process of development of Xilinx I2C IP core driver and I've run into the problem: the ISR for level-based IRQ is called twice. It looks like level IRQ handling on Xilinx INTC with ARCH=powerpc is currently broken as Xilinx INTC requires IRQ acknowledg

Re: Level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-07-29 Thread David Howells
Sergey Temerkhanov <[EMAIL PROTECTED]> wrote: > And handle_level_irq() which is currently used as high-level IRQ handler for > Xilinx INTC only tries to acknowledge IRQ before ISR call. So that the IRQ > remains asserted in INTC and after the call to desc->chip->unmask() causes > spurious attempt

Re: Level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-07-29 Thread Benjamin Herrenschmidt
On Tue, 2008-07-29 at 15:14 +0100, David Howells wrote: > Sergey Temerkhanov <[EMAIL PROTECTED]> wrote: > > > And handle_level_irq() which is currently used as high-level IRQ handler for > > Xilinx INTC only tries to acknowledge IRQ before ISR call. So that the IRQ > > remains asserted in INTC and

[PATCH] Re: Level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-08-08 Thread Sergey Temerkhanov
I've prepared the patch to fix the problem being discussed. It adds a field flags to struct irq_chip. If IRQ_CHIP_UNMASK_ACK is set in this field, acknowledge is performed before unmasking. The patch is against 2.6.26 diff -r 6b0915754563 arch/powerpc/sysdev/xilinx_intc.c --- a/arch/powerpc/sysd

[PATCH] [RFC] Fix level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-08-25 Thread Sergey Temerkhanov
This fixes the missing acknowledge at the end of handle_level_irq(). It adds a field flags to struct irq_chip. If IRQ_CHIP_UNMASK_ACK is set in this field, acknowledge is performed before unmasking. diff -r 6b0915754563 arch/powerpc/sysdev/xilinx_intc.c --- a/arch/powerpc/sysdev/xilinx_intc.c Mon

Re: [PATCH] [RFC] Fix level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-08-25 Thread Grant Likely
On Mon, Aug 25, 2008 at 6:55 AM, Sergey Temerkhanov <[EMAIL PROTECTED]> wrote: > This fixes the missing acknowledge at the end of handle_level_irq(). > > It adds a field flags to struct irq_chip. If IRQ_CHIP_UNMASK_ACK is set in > this field, acknowledge is performed before unmasking. Can this fix

Re: [PATCH] [RFC] Fix level IRQ handling on Xilinx INTC with ARCH=powerpc

2008-08-25 Thread Sergey Temerkhanov
On Monday 25 August 2008 18:26:54 Grant Likely wrote: >This > patch unconditionally adds what is essentially a device specific fixup > to *every* Linux platform. I cannot see that flying very far. > I know that. But without IRQ_CHIP_UNMASK_ACK set this fixup won'be applied so setups that are not