From 9ed68f522fc84ca65c6f0fe28e7d1316837516dd Mon Sep 17 00:00:00 2001 From: Alexander Gordeev Date: Mon, 16 Dec 2013 09:34:57 +0100 Subject: PCI/MSI: Return -ENOSYS for unimplemented interfaces, not -1 Suggested-by: Ben Hutchings Signed-off-by: Alexander Gordeev Signed-off-by: Bjorn Helgaas Reviewed-by: Tejun Heo (cherry picked from commit 8ec5db6b20c860ddd1311c794b38c98ce86ac7ae) (cherry picked from commit aa1eee2e30c2c88c89bc9c8028c1538473ba41b1) --- include/linux/pci.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/linux/pci.h b/include/linux/pci.h index 13b4be7c1413..24ea555b8c65 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -1127,7 +1127,7 @@ static inline int pci_msi_vec_count(struct pci_dev *dev) static inline int pci_enable_msi_block(struct pci_dev *dev, int nvec) { - return -1; + return -ENOSYS; } static inline void pci_msi_shutdown(struct pci_dev *dev) @@ -1142,7 +1142,7 @@ static inline int pci_msix_vec_count(struct pci_dev *dev) static inline int pci_enable_msix(struct pci_dev *dev, struct msix_entry *entries, int nvec) { - return -1; + return -ENOSYS; } static inline void pci_msix_shutdown(struct pci_dev *dev) -- cgit v1.2.3