Paul Mackerras <[EMAIL PROTECTED]> writes:
> Eric W. Biederman writes:
>
>> @@ -693,15 +664,14 @@ int pci_enable_msi(struct pci_dev* dev)
>> if (!pos)
>> return -EINVAL;
>>
>> -WARN_ON(!msi_lookup_irq(dev, PCI_CAP_ID_MSI));
>> +WARN_ON(!!dev->msi_enabled);
>
> Minor nit
Eric W. Biederman writes:
> @@ -693,15 +664,14 @@ int pci_enable_msi(struct pci_dev* dev)
> if (!pos)
> return -EINVAL;
>
> - WARN_ON(!msi_lookup_irq(dev, PCI_CAP_ID_MSI));
> + WARN_ON(!!dev->msi_enabled);
Minor nit: what's wrong with just WARN_ON(dev->msi_enabled) ?
The function msi_lookup_irq was horrible. As a side effect of running
it changed dev->irq, and then the callers would need to change it
back. In addition it does a global scan through all of the irqs,
which seems to be the sole justification of the msi_lock.
To remove the neede for msi_lookup_i
3 matches
Mail list logo