Skip to content
Commit d5582854 authored by Thomas Gleixner's avatar Thomas Gleixner
Browse files

PCI/MSI: Unbreak pci_irq_get_affinity()

The recent cleanup of pci_irq_get_affinity() broke the function for
PCI/MSI-X and indices > 0. Only the MSI descriptor for PCI/MSI has more
than one affinity mask which can be retrieved via the MSI index.

PCI/MSI-X has one descriptor per vector and each has a single affinity
mask.

Use index 0 when accessing the affinity mask in the MSI descriptor when
MSI-X is enabled.

Fixes: f4823590

 ("PCI/MSI: Simplify pci_irq_get_affinity()")
Reported-by: default avatarNathan Chancellor <nathan@kernel.org>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Tested-by: default avatarNathan Chancellor <nathan@kernel.org>
Link: https://lore.kernel.org/r/87v8zm9pmd.ffs@tglx
parent cd6cf065
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment