diff options
author | hselasky <hselasky@FreeBSD.org> | 2016-12-19 09:41:49 +0000 |
---|---|---|
committer | hselasky <hselasky@FreeBSD.org> | 2016-12-19 09:41:49 +0000 |
commit | 32883c890314b7942b65af4fa18b076c9eccf86e (patch) | |
tree | ab058fad451c3a179a124a97ad5850ab745ad0a0 | |
parent | 18c577fbca101a5c16719ae2820616b45c3df493 (diff) | |
download | FreeBSD-src-32883c890314b7942b65af4fa18b076c9eccf86e.zip FreeBSD-src-32883c890314b7942b65af4fa18b076c9eccf86e.tar.gz |
MFC r309733:
MSIX can support more than 256 IRQs. Make sure the invalid IRQ number
set in the LinuxKPI is big enough.
Sponsored by: Mellanox Technologies
-rw-r--r-- | sys/compat/linuxkpi/common/include/linux/device.h | 1 | ||||
-rw-r--r-- | sys/compat/linuxkpi/common/src/linux_pci.c | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/device.h b/sys/compat/linuxkpi/common/include/linux/device.h index 2f43d81..3bb1e03 100644 --- a/sys/compat/linuxkpi/common/include/linux/device.h +++ b/sys/compat/linuxkpi/common/include/linux/device.h @@ -70,6 +70,7 @@ struct device { uint64_t *dma_mask; void *driver_data; unsigned int irq; +#define LINUX_IRQ_INVALID 65535 unsigned int msix; unsigned int msix_max; const struct attribute_group **groups; diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index cc95ea6..e614fef 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -144,7 +144,7 @@ linux_pci_attach(device_t dev) if (rle) pdev->dev.irq = rle->start; else - pdev->dev.irq = 255; + pdev->dev.irq = LINUX_IRQ_INVALID; pdev->irq = pdev->dev.irq; DROP_GIANT(); spin_lock(&pci_lock); |