diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2021-12-07 01:51:18 +0300 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2021-12-17 00:22:18 +0300 |
commit | ae24e28fef14687a26f98050e64153b8e4fee7c7 (patch) | |
tree | 3a0b72723febf6da23b97c369ac46a42f57b7952 /drivers/pci/msi/irqdomain.c | |
parent | 9fb9eb4b59acc607e978288c96ac7efa917153d4 (diff) | |
download | linux-ae24e28fef14687a26f98050e64153b8e4fee7c7.tar.xz |
PCI/MSI: Use msi_on_each_desc()
Use the new iterator functions which pave the way for dynamically extending
MSI-X vectors.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Michael Kelley <mikelley@microsoft.com>
Tested-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Link: https://lore.kernel.org/r/20211206210748.142603657@linutronix.de
Diffstat (limited to 'drivers/pci/msi/irqdomain.c')
-rw-r--r-- | drivers/pci/msi/irqdomain.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/msi/irqdomain.c b/drivers/pci/msi/irqdomain.c index 3aab61714abe..0d63541c4052 100644 --- a/drivers/pci/msi/irqdomain.c +++ b/drivers/pci/msi/irqdomain.c @@ -83,7 +83,7 @@ static int pci_msi_domain_check_cap(struct irq_domain *domain, struct msi_domain_info *info, struct device *dev) { - struct msi_desc *desc = first_pci_msi_entry(to_pci_dev(dev)); + struct msi_desc *desc = msi_first_desc(dev, MSI_DESC_ALL); /* Special handling to support __pci_enable_msi_range() */ if (pci_msi_desc_is_multi_msi(desc) && @@ -98,7 +98,7 @@ static int pci_msi_domain_check_cap(struct irq_domain *domain, unsigned int idx = 0; /* Check for gaps in the entry indices */ - for_each_msi_entry(desc, dev) { + msi_for_each_desc(desc, dev, MSI_DESC_ALL) { if (desc->msi_index != idx++) return -ENOTSUPP; } |