scsi: hpsa: use pci_alloc_irq_vectors and automatic irq affinity
authorChristoph Hellwig <hch@lst.de>
Wed, 9 Nov 2016 18:42:22 +0000 (10:42 -0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Sat, 12 Nov 2016 15:11:06 +0000 (10:11 -0500)
commitbc2bb1543e62a5d0ae51ccdfde697dc97957f2a1
tree189786e08f4ebd707f49345a010a4938d32a681b
parent4861ee15f2b7dee17a869d9edd3463b812f77636
scsi: hpsa: use pci_alloc_irq_vectors and automatic irq affinity

This patch converts over hpsa to use the pci_alloc_irq_vectors including
the PCI_IRQ_AFFINITY flag that automatically assigns spread out irq
affinity to the I/O queues.

It also cleans up the per-ctrl interrupt state due to the use of the
pci_irq_vector and pci_free_irq_vectors helpers that don't need to know
the exact irq type.  Additionally it changes a little oddity in the
existing code that was using different array indixes into the per-vector
arrays depending on whether a controller is using a single INTx or
single MSI irq.

[mkp: fixed typo]

Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Don Brace <don.brace@microsemi.com>
Tested-by: Don Brace <don.brace@microsemi.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/hpsa.c
drivers/scsi/hpsa.h