# Re: \[PATCH v2 14/15\] ARM: dts: bcm2711: Add the BSC interrupt controller

- From: Marc Zyngier \<maz@kernel.org\>
- Date: 2021-02-10 15:31:37 
- List: linux-arm-kernel
- Page: https://ratatoskr.run/linux-arm-kernel/2021/02/6266015
- Thread: https://ratatoskr.run/linux-arm-kernel/2021/01/6230146/t.md

```text
Hi Maxime,

On 2021-02-10 14:40, Maxime Ripard wrote:
> Hi Dave,
>
> On Tue, Feb 09, 2021 at 09:49:05AM +0000, Dave Stevenson wrote:
>> On Mon, 11 Jan 2021 at 14:23, Maxime Ripard [ref] wrote:
>> >
>> > The BSC controllers used for the HDMI DDC have an interrupt controller
>> > shared between both instances. Let's add it to avoid polling.
>>
>> This seems to have unintended side effects.
>> GIC interrupt 117 is shared between the standard I2C controllers
>> (i2c-bcm2835) and the l2-intc block handling the HDMI I2C interrupts.
>>
>> Whilst i2c-bcm2835 requests the interrupt with IRQF_SHARED, that
>> doesn't appear to be an option for l2-intc registering as an interrupt
>> controller. i2c-bcm2835 therefore loses out and fails to register for
>> the interrupt.
>>
>> Is there an equivalent flag that an interrupt controller can add to
>> say that the parent interrupt is shared? Is that even supported?
>
> Indeed, it looks like setting an equivalent to IRQF_SHARED would be the
> solution, but I couldn't find anything that would allow us to in the
> irqchip code.
>
> Marc, Thomas, is it something that is allowed?

No, not really. That's because the chained handler is actually an
interrupt flow, and not a normal handler. IRQF_SHARED acts at the wrong
level for that.

I can see two possibilities:

- the l2-intc gets turned into a normal handler, and does the demux
  from there. Horrible stuff.

- the i2c controller gets parented to the l2c-int as a fake interrupt,
  and gets called from there. Horrible stuff.

Pick your poison... :-/

        M.
-- 
Jazz is not dead. It just smells funny...

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
```
