Commit 0ce57f8a authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Tejun Heo

ahci: fix the single MSI-X case in ahci_init_one

We need to make sure hpriv->irq is set properly if we don't use per-port
vectors, so switch from blindly assigning pdev->irq to using
pci_irq_vector, which handles all interrupt types correctly.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Reported-by: default avatarRobert Richter <robert.richter@cavium.com>
Tested-by: default avatarRobert Richter <robert.richter@cavium.com>
Tested-by: default avatarDavid Daney <ddaney.cavm@gmail.com>
Fixes: 0b9e2988 ("ahci: use pci_alloc_irq_vectors")
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent a478b097
...@@ -1620,7 +1620,7 @@ static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) ...@@ -1620,7 +1620,7 @@ static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
/* legacy intx interrupts */ /* legacy intx interrupts */
pci_intx(pdev, 1); pci_intx(pdev, 1);
} }
hpriv->irq = pdev->irq; hpriv->irq = pci_irq_vector(pdev, 0);
if (!(hpriv->cap & HOST_CAP_SSS) || ahci_ignore_sss) if (!(hpriv->cap & HOST_CAP_SSS) || ahci_ignore_sss)
host->flags |= ATA_HOST_PARALLEL_SCAN; host->flags |= ATA_HOST_PARALLEL_SCAN;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment