Re: [patch V2 18/19] PCI/MSI: Provide a new set of mask and unmask functions

From: Thomas Gleixner
Date: Mon Aug 09 2021 - 14:56:39 EST


On Fri, Aug 06 2021 at 15:39, Marc Zyngier wrote:
> On Thu, 29 Jul 2021 22:51:57 +0100,
> Thomas Gleixner <tglx@xxxxxxxxxxxxx> wrote:
>> +static void __pci_msi_mask_desc(struct msi_desc *desc, u32 mask)
>> +{
>> + if (pci_msi_ignore_mask || desc->msi_attrib.is_virtual)
>> + return;
>> +
>> + if (desc->msi_attrib.is_msix)
>> + pci_msix_mask(desc);
>> + else if (!desc->msi_attrib.maskbit)
>
> This negation is preventing one of my boxes from working correctly (no
> idea why the i350 driver refuses to use MSI-X and sticks to a single
> MSI, but hey, that's another story), as the device supports MSI
> masking, and we definitely don't try to mask/unmask in this case...
>
> Dropping the '!' here and on the unmask path fixes it for me.

Duh. I'm a moron. Of course this needs to check maskbit if it wants to
mask. Sigh.