[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20221123064502.2061-1-angus.chen@jaguarmicro.com>
Date: Wed, 23 Nov 2022 14:45:02 +0800
From: Angus Chen <angus.chen@...uarmicro.com>
To: bhelgaas@...gle.com, sr@...x.de, pali@...nel.org
Cc: linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org,
Angus Chen <angus.chen@...uarmicro.com>
Subject: [PATCH] PCI/portdrv: Use ENOSPC instead of EIO
If pcie_message_numbers can't provide the vector cap
which pme&aer&dpc requested,it should be return ENOSPC for better.
No functional change intended.
Signed-off-by: Angus Chen <angus.chen@...uarmicro.com>
---
drivers/pci/pcie/portdrv_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/pcie/portdrv_core.c b/drivers/pci/pcie/portdrv_core.c
index 1ac7fec47d6f..473a70210313 100644
--- a/drivers/pci/pcie/portdrv_core.c
+++ b/drivers/pci/pcie/portdrv_core.c
@@ -113,7 +113,7 @@ static int pcie_port_enable_irq_vec(struct pci_dev *dev, int *irqs, int mask)
nvec = pcie_message_numbers(dev, mask, &pme, &aer, &dpc);
if (nvec > nr_entries) {
pci_free_irq_vectors(dev);
- return -EIO;
+ return -ENOSPC;
}
/*
--
2.25.1
Powered by blists - more mailing lists