diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2014-02-22 21:46:52 +0100 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2014-02-24 00:07:45 +0100 |
commit | 1d8dffe0ff1395cf423f92018d74572338b8add2 (patch) | |
tree | 65fd0f7daf679a0b7453a03d2af2c86be1e58e29 /backport/backport-include | |
parent | 1675a771ab6578bbd766de27fcda51129d5a559a (diff) |
backports: add pci_enable_msi_range()
This is needed by drivers/net/wireless/ath/wil6210/pcie_bus.c
pci_enable_msi_block() was added in kernel 2.6.30, so this does not
work on older kernel versions.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Diffstat (limited to 'backport/backport-include')
-rw-r--r-- | backport/backport-include/linux/pci.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/backport/backport-include/linux/pci.h b/backport/backport-include/linux/pci.h index 2d4822a9..2190831d 100644 --- a/backport/backport-include/linux/pci.h +++ b/backport/backport-include/linux/pci.h @@ -233,4 +233,16 @@ static inline int pci_vfs_assigned(struct pci_dev *dev) #endif #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3,10,0) */ + +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3,14,0)) && (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,30)) +#define pci_enable_msi_range LINUX_BACKPORT(pci_enable_msi_range) +#ifdef CONFIG_PCI_MSI +int pci_enable_msi_range(struct pci_dev *dev, int minvec, int maxvec); +#else +static inline int pci_enable_msi_range(struct pci_dev *dev, int minvec, + int maxvec) +{ return -ENOSYS; } +#endif +#endif + #endif /* _BACKPORT_LINUX_PCI_H */ |