Jared McNeill <jmcne...@invisible.ca> wrote:
>On Wed, 28 Nov 2018, Jaromír Doleček wrote:
>
>> pci_intr_alloc() checks what the device claims to support down the
>> call stack, reading the PCI config space. I assume there some
>> negotiation between the PCI bus and the device. I hope device can't
>> claim to support e.g. MSI-X if the bus doesn't.
>
>Device claiming to support MSI-X is fine. The bus should only set 
>PCI_FLAGS_MSIX_OKAY in its pcibus_attach_args pba_flags in the case that 
>MSI-X is supported, and then the MD code will filter it out:

I traced through what one of my non-MSI machines does at boot.

The wm(4) driver asks for MSI-X interrupts, the MD PCI code gives it an
INTx interrupt, the driver sets things up correctly to use the returned
interrupt, it doesn't loop in the driver retrying the pci_intr_alloc().

Reply via email to