On 11/18/2016 07:10 AM, Christoph Hellwig wrote: > Signed-off-by: Christoph Hellwig <hch@xxxxxx> > --- > drivers/scsi/isci/host.h | 1 - > drivers/scsi/isci/init.c | 21 +++++++++------------ > 2 files changed, 9 insertions(+), 13 deletions(-) > > diff --git a/drivers/scsi/isci/host.h b/drivers/scsi/isci/host.h > index 22a9bb1..b353992 100644 > --- a/drivers/scsi/isci/host.h > +++ b/drivers/scsi/isci/host.h > @@ -295,7 +295,6 @@ enum sci_controller_states { > #define SCI_MAX_MSIX_INT (SCI_NUM_MSI_X_INT*SCI_MAX_CONTROLLERS) > > struct isci_pci_info { > - struct msix_entry msix_entries[SCI_MAX_MSIX_INT]; > struct isci_host *hosts[SCI_MAX_CONTROLLERS]; > struct isci_orom *orom; > }; > diff --git a/drivers/scsi/isci/init.c b/drivers/scsi/isci/init.c > index 77128d68..7cddebb 100644 > --- a/drivers/scsi/isci/init.c > +++ b/drivers/scsi/isci/init.c > @@ -350,16 +350,12 @@ static int isci_setup_interrupts(struct pci_dev *pdev) > */ > num_msix = num_controllers(pdev) * SCI_NUM_MSI_X_INT; > > - for (i = 0; i < num_msix; i++) > - pci_info->msix_entries[i].entry = i; > - > - err = pci_enable_msix_exact(pdev, pci_info->msix_entries, num_msix); > + err = pci_alloc_irq_vectors(pdev, num_msix, num_msix, PCI_IRQ_MSIX); > if (err) > goto intx; pci_enable_msix_exact() returns 0 or -ERROR but pci_alloc_irq_vectors() returns the number of vectors allocated if successful, so this also should be changed: - if (err) + if (err < 0) goto intx; The rest looks good to me. Thanks, Artur -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html