Re: [PATCH+DISCUSSION] irqchip: armada-370-xp: Remove redundant ops assignment

From: Benjamin Herrenschmidt
Date: Thu Jun 13 2019 - 11:36:33 EST


On Thu, 2019-06-13 at 10:22 +0100, Marc Zyngier wrote:
>
> It looks to me that masking at the PCI level is rather superfluous as
> long as the MSI controller HW has the capability to mask the interrupt
> on a per MSI basis. After all, most non MSI-X endpoint lack support
> for masking of individual vectors, so I think that we should just mask
> things at the irqchip level. This is also consistent with what you'd
> have to do for non-PCI MSI, where nothing standardises the MSI
> masking.
>
> I think this is in effect a split in responsibilities:
>
> - the end-point driver should (directly or indirectly) control the
> interrupt generation at the end-point level,
>
> - the MSI controller driver should control the signalling of the MSI
> to the CPU.
>
> The only case where we should rely on masking interrupts at the
> end-point level is when the MSI controller doesn't provide a method to
> do so (hopefully a rare exception).

While I would tend to agree, I'm also wary of standardizing on
something which isn't what x86 does today :-)

You know what happens when we break them... interestingly enough they
(like quite a few other drivers) don't even bother trying to mask at
the APIC level unless I misread the code. That means that for endpoints
that don't support masking, they just get those MSIs and
"ignore" them...

But I'll look into it, see what the patch looks like.

I've also looked at trying to make the "inner domain" more generic but
that's looking a tad trickier... not giving up yet though :-)

Cheers,
Ben.