[PATCH] NVMe: Use pci_dev->msix_enabled instead of pci_dev->irq
Yijing Wang
wangyijing at huawei.com
Fri Feb 6 20:00:01 PST 2015
We should use msi_enabled flag to check whether MSI-X
was enabled, it's better than rough use pci_dev->irq.
Signed-off-by: Yijing Wang <wangyijing at huawei.com>
---
drivers/block/nvme-core.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/block/nvme-core.c b/drivers/block/nvme-core.c
index b3cb67d..646da30 100644
--- a/drivers/block/nvme-core.c
+++ b/drivers/block/nvme-core.c
@@ -2099,7 +2099,7 @@ static int nvme_setup_io_queues(struct nvme_dev *dev)
* If we enable msix early due to not intx, disable it again before
* setting up the full range we need.
*/
- if (!pdev->irq)
+ if (pdev->msix_enabled)
pci_disable_msix(pdev);
for (i = 0; i < nr_io_queues; i++)
--
1.7.1
More information about the Linux-nvme
mailing list