2014-04-14 08:33:12

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 00/23] scsi: Use pci_enable_msix_range() instead of pci_enable_msix()

Hello,

This series is against 3.15-rc1.

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

There are no major changes in this series since I posted
it last time.

Thanks!

Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]


Alexander Gordeev (23):
be2iscsi: Use pci_enable_msix_exact() instead of pci_enable_msix()
bfa: Do not call pci_enable_msix() after it failed once
bfa: Cleanup bfad_setup_intr() function
bfa: Use pci_enable_msix_exact() instead of pci_enable_msix()
csiostor: Remove superfluous call to pci_disable_msix()
csiostor: Use pci_enable_msix_range() instead of pci_enable_msix()
fnic: Use pci_enable_msix_exact() instead of pci_enable_msix()
isci: Use pci_enable_msix_exact() instead of pci_enable_msix()
hpsa: Fallback to MSI rather than to INTx if MSI-X failed
hpsa: Use pci_enable_msix_range() instead of pci_enable_msix()
lpfc: Remove superfluous call to pci_disable_msix()
lpfc: Use pci_enable_msix_range() instead of pci_enable_msix()
megaraid: Fail resume if MSI-X re-initialization failed
megaraid: Use pci_enable_msix_range() instead of pci_enable_msix()
mpt2sas: Use pci_enable_msix_exact() instead of pci_enable_msix()
mpt3sas: Use pci_enable_msix_exact() instead of pci_enable_msix()
pm8001: Fix invalid return when request_irq() failed
pm8001: Use pci_enable_msix_exact() instead of pci_enable_msix()
pmcraid: Get rid of a redundant assignment
pmcraid: Use pci_enable_msix_range() instead of pci_enable_msix()
qla2xxx: Use pci_enable_msix_range() instead of pci_enable_msix()
qla4xxx: Use pci_enable_msix_exact() instead of pci_enable_msix()
vmw_pvscsi: Use pci_enable_msix_exact() instead of pci_enable_msix()

drivers/scsi/be2iscsi/be_main.c | 6 +--
drivers/scsi/bfa/bfad.c | 62 ++++++++++++-----------------
drivers/scsi/csiostor/csio_hw.h | 2 +-
drivers/scsi/csiostor/csio_isr.c | 24 ++++-------
drivers/scsi/fnic/fnic_isr.c | 4 +-
drivers/scsi/hpsa.c | 30 ++++++--------
drivers/scsi/isci/init.c | 2 +-
drivers/scsi/lpfc/lpfc_init.c | 47 +++++++++++-----------
drivers/scsi/megaraid/megaraid_sas_base.c | 24 +++++------
drivers/scsi/mpt2sas/mpt2sas_base.c | 6 +-
drivers/scsi/mpt3sas/mpt3sas_base.c | 4 +-
drivers/scsi/pm8001/pm8001_init.c | 44 +++++++++++----------
drivers/scsi/pmcraid.c | 14 +------
drivers/scsi/qla2xxx/qla_isr.c | 27 +++++-------
drivers/scsi/qla4xxx/ql4_nx.c | 2 +-
drivers/scsi/vmw_pvscsi.c | 2 +-
16 files changed, 129 insertions(+), 171 deletions(-)

--
1.7.7.6


2014-04-14 08:04:36

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 16/23] mpt3sas: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Nagalakshmi Nandigama <[email protected]>
Cc: Sreekanth Reddy <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/mpt3sas/mpt3sas_base.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c
index 0cf4f70..7b65ec2 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_base.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_base.c
@@ -1747,10 +1747,10 @@ _base_enable_msix(struct MPT3SAS_ADAPTER *ioc)
for (i = 0, a = entries; i < ioc->reply_queue_count; i++, a++)
a->entry = i;

- r = pci_enable_msix(ioc->pdev, entries, ioc->reply_queue_count);
+ r = pci_enable_msix_exact(ioc->pdev, entries, ioc->reply_queue_count);
if (r) {
dfailprintk(ioc, pr_info(MPT3SAS_FMT
- "pci_enable_msix failed (r=%d) !!!\n",
+ "pci_enable_msix_exact failed (r=%d) !!!\n",
ioc->name, r));
kfree(entries);
goto try_ioapic;
--
1.7.7.6

2014-04-14 08:04:42

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 19/23] pmcraid: Get rid of a redundant assignment

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Ravindranath <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/pmcraid.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c
index be8ce54..c06af7f 100644
--- a/drivers/scsi/pmcraid.c
+++ b/drivers/scsi/pmcraid.c
@@ -4746,7 +4746,6 @@ pmcraid_isr_legacy:
pinstance->hrrq_vector[0].drv_inst = pinstance;
pinstance->hrrq_vector[0].vector = pdev->irq;
pinstance->num_hrrq = 1;
- rc = 0;

rc = request_irq(pdev->irq, pmcraid_isr, IRQF_SHARED,
PMCRAID_DRIVER_NAME, &pinstance->hrrq_vector[0]);
--
1.7.7.6

2014-04-14 08:04:59

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 22/23] qla4xxx: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Vikas Chaudhary <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/qla4xxx/ql4_nx.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/qla4xxx/ql4_nx.c b/drivers/scsi/qla4xxx/ql4_nx.c
index 63328c8..a3e69e6 100644
--- a/drivers/scsi/qla4xxx/ql4_nx.c
+++ b/drivers/scsi/qla4xxx/ql4_nx.c
@@ -3787,7 +3787,7 @@ qla4_8xxx_enable_msix(struct scsi_qla_host *ha)
for (i = 0; i < QLA_MSIX_ENTRIES; i++)
entries[i].entry = qla4_8xxx_msix_entries[i].entry;

- ret = pci_enable_msix(ha->pdev, entries, ARRAY_SIZE(entries));
+ ret = pci_enable_msix_exact(ha->pdev, entries, ARRAY_SIZE(entries));
if (ret) {
ql4_printk(KERN_WARNING, ha,
"MSI-X: Failed to enable support -- %d/%d\n",
--
1.7.7.6

2014-04-14 08:05:30

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 09/23] hpsa: Fallback to MSI rather than to INTx if MSI-X failed

Currently the driver falls back to INTx mode when MSI-X
initialization failed. This is a suboptimal behaviour
for chips that also support MSI. This update changes that
behaviour and falls back to MSI mode in case MSI-X mode
initialization failed.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: "Stephen M. Cameron" <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/hpsa.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c
index 8cf4a0c..3284edb 100644
--- a/drivers/scsi/hpsa.c
+++ b/drivers/scsi/hpsa.c
@@ -6162,7 +6162,6 @@ static void hpsa_interrupt_mode(struct ctlr_info *h)
dev_warn(&h->pdev->dev, "MSI-X init failed %d\n",
err);
h->msix_vector = 0;
- goto default_int_mode;
}
}
if (pci_find_capability(h->pdev, PCI_CAP_ID_MSI)) {
--
1.7.7.6

2014-04-14 08:06:36

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 10/23] hpsa: Use pci_enable_msix_range() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: "Stephen M. Cameron" <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/hpsa.c | 29 +++++++++++++----------------
1 files changed, 13 insertions(+), 16 deletions(-)

diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c
index 3284edb..36bb1e4 100644
--- a/drivers/scsi/hpsa.c
+++ b/drivers/scsi/hpsa.c
@@ -6144,26 +6144,23 @@ static void hpsa_interrupt_mode(struct ctlr_info *h)
goto default_int_mode;
if (pci_find_capability(h->pdev, PCI_CAP_ID_MSIX)) {
dev_info(&h->pdev->dev, "MSIX\n");
- h->msix_vector = MAX_REPLY_QUEUES;
- err = pci_enable_msix(h->pdev, hpsa_msix_entries,
- h->msix_vector);
- if (err > 0) {
+ err = pci_enable_msix_range(h->pdev, hpsa_msix_entries,
+ 1, MAX_REPLY_QUEUES);
+ if (err < 0) {
+ dev_warn(&h->pdev->dev, "MSI-X init failed %d\n", err);
+ h->msix_vector = 0;
+ goto single_msi_mode;
+ } else if (err < MAX_REPLY_QUEUES) {
dev_warn(&h->pdev->dev, "only %d MSI-X vectors "
"available\n", err);
- h->msix_vector = err;
- err = pci_enable_msix(h->pdev, hpsa_msix_entries,
- h->msix_vector);
- }
- if (!err) {
- for (i = 0; i < h->msix_vector; i++)
- h->intr[i] = hpsa_msix_entries[i].vector;
- return;
- } else {
- dev_warn(&h->pdev->dev, "MSI-X init failed %d\n",
- err);
- h->msix_vector = 0;
}
+
+ h->msix_vector = err;
+ for (i = 0; i < h->msix_vector; i++)
+ h->intr[i] = hpsa_msix_entries[i].vector;
+ return;
}
+single_msi_mode:
if (pci_find_capability(h->pdev, PCI_CAP_ID_MSI)) {
dev_info(&h->pdev->dev, "MSI\n");
if (!pci_enable_msi(h->pdev))
--
1.7.7.6

2014-04-14 08:04:55

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 17/23] pm8001: Fix invalid return when request_irq() failed

When a call to request_irq() failed pm8001_setup_msix()
still returns the success. This udate fixes the described
misbehaviour.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Acked-by: Jack Wang <[email protected]>
---
drivers/scsi/pm8001/pm8001_init.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/pm8001/pm8001_init.c b/drivers/scsi/pm8001/pm8001_init.c
index c4f31b21..df421f5 100644
--- a/drivers/scsi/pm8001/pm8001_init.c
+++ b/drivers/scsi/pm8001/pm8001_init.c
@@ -740,9 +740,10 @@ static u32 pm8001_setup_msix(struct pm8001_hba_info *pm8001_ha)
pm8001_ha->irq_vector[i].irq_id = i;
pm8001_ha->irq_vector[i].drv_inst = pm8001_ha;

- if (request_irq(pm8001_ha->msix_entries[i].vector,
+ rc = request_irq(pm8001_ha->msix_entries[i].vector,
pm8001_interrupt_handler_msix, flag,
- intr_drvname[i], &(pm8001_ha->irq_vector[i]))) {
+ intr_drvname[i], &(pm8001_ha->irq_vector[i]));
+ if (rc) {
for (j = 0; j < i; j++)
free_irq(
pm8001_ha->msix_entries[j].vector,
--
1.7.7.6

2014-04-14 08:04:52

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 18/23] pm8001: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/pm8001/pm8001_init.c | 39 +++++++++++++++++++------------------
1 files changed, 20 insertions(+), 19 deletions(-)

diff --git a/drivers/scsi/pm8001/pm8001_init.c b/drivers/scsi/pm8001/pm8001_init.c
index df421f5..1d3c02d 100644
--- a/drivers/scsi/pm8001/pm8001_init.c
+++ b/drivers/scsi/pm8001/pm8001_init.c
@@ -725,34 +725,35 @@ static u32 pm8001_setup_msix(struct pm8001_hba_info *pm8001_ha)
sizeof(pm8001_ha->msix_entries[0]);
for (i = 0; i < max_entry ; i++)
pm8001_ha->msix_entries[i].entry = i;
- rc = pci_enable_msix(pm8001_ha->pdev, pm8001_ha->msix_entries,
+ rc = pci_enable_msix_exact(pm8001_ha->pdev, pm8001_ha->msix_entries,
number_of_intr);
pm8001_ha->number_of_intr = number_of_intr;
- if (!rc) {
- PM8001_INIT_DBG(pm8001_ha, pm8001_printk(
- "pci_enable_msix request ret:%d no of intr %d\n",
- rc, pm8001_ha->number_of_intr));
+ if (rc)
+ return rc;

+ PM8001_INIT_DBG(pm8001_ha, pm8001_printk(
+ "pci_enable_msix_exact request ret:%d no of intr %d\n",
+ rc, pm8001_ha->number_of_intr));

- for (i = 0; i < number_of_intr; i++) {
- snprintf(intr_drvname[i], sizeof(intr_drvname[0]),
- DRV_NAME"%d", i);
- pm8001_ha->irq_vector[i].irq_id = i;
- pm8001_ha->irq_vector[i].drv_inst = pm8001_ha;
+ for (i = 0; i < number_of_intr; i++) {
+ snprintf(intr_drvname[i], sizeof(intr_drvname[0]),
+ DRV_NAME"%d", i);
+ pm8001_ha->irq_vector[i].irq_id = i;
+ pm8001_ha->irq_vector[i].drv_inst = pm8001_ha;

- rc = request_irq(pm8001_ha->msix_entries[i].vector,
- pm8001_interrupt_handler_msix, flag,
- intr_drvname[i], &(pm8001_ha->irq_vector[i]));
- if (rc) {
- for (j = 0; j < i; j++)
- free_irq(
- pm8001_ha->msix_entries[j].vector,
+ rc = request_irq(pm8001_ha->msix_entries[i].vector,
+ pm8001_interrupt_handler_msix, flag,
+ intr_drvname[i], &(pm8001_ha->irq_vector[i]));
+ if (rc) {
+ for (j = 0; j < i; j++) {
+ free_irq(pm8001_ha->msix_entries[j].vector,
&(pm8001_ha->irq_vector[i]));
- pci_disable_msix(pm8001_ha->pdev);
- break;
}
+ pci_disable_msix(pm8001_ha->pdev);
+ break;
}
}
+
return rc;
}
#endif
--
1.7.7.6

2014-04-14 08:04:49

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 23/23] vmw_pvscsi: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Arvind Kumar <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Acked-by: Arvind Kumar <[email protected]>
---
drivers/scsi/vmw_pvscsi.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/vmw_pvscsi.c b/drivers/scsi/vmw_pvscsi.c
index c88e146..598f65e 100644
--- a/drivers/scsi/vmw_pvscsi.c
+++ b/drivers/scsi/vmw_pvscsi.c
@@ -1194,7 +1194,7 @@ static int pvscsi_setup_msix(const struct pvscsi_adapter *adapter,
struct msix_entry entry = { 0, PVSCSI_VECTOR_COMPLETION };
int ret;

- ret = pci_enable_msix(adapter->dev, &entry, 1);
+ ret = pci_enable_msix_exact(adapter->dev, &entry, 1);
if (ret)
return ret;

--
1.7.7.6

2014-04-14 08:14:07

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 21/23] qla2xxx: Use pci_enable_msix_range() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Log message code 0x00c6 preserved, although it is reported
after successful call to pci_enable_msix_range(), not before
possibly unsuccessful call to pci_enable_msix(). Consumers
of the error code should not notice the difference.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/qla2xxx/qla_isr.c | 27 +++++++++++----------------
1 files changed, 11 insertions(+), 16 deletions(-)

diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index 95314ef..41eb0dc 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -2918,27 +2918,22 @@ qla24xx_enable_msix(struct qla_hw_data *ha, struct rsp_que *rsp)
for (i = 0; i < ha->msix_count; i++)
entries[i].entry = i;

- ret = pci_enable_msix(ha->pdev, entries, ha->msix_count);
- if (ret) {
- if (ret < MIN_MSIX_COUNT)
- goto msix_failed;
-
+ ret = pci_enable_msix_range(ha->pdev,
+ entries, MIN_MSIX_COUNT, ha->msix_count);
+ if (ret < 0) {
+ ql_log(ql_log_fatal, vha, 0x00c7,
+ "MSI-X: Failed to enable support, "
+ "giving up -- %d/%d.\n",
+ ha->msix_count, ret);
+ goto msix_out;
+ } else if (ret < ha->msix_count) {
ql_log(ql_log_warn, vha, 0x00c6,
"MSI-X: Failed to enable support "
"-- %d/%d\n Retry with %d vectors.\n",
ha->msix_count, ret, ret);
- ha->msix_count = ret;
- ret = pci_enable_msix(ha->pdev, entries, ha->msix_count);
- if (ret) {
-msix_failed:
- ql_log(ql_log_fatal, vha, 0x00c7,
- "MSI-X: Failed to enable support, "
- "giving up -- %d/%d.\n",
- ha->msix_count, ret);
- goto msix_out;
- }
- ha->max_rsp_queues = ha->msix_count - 1;
}
+ ha->msix_count = ret;
+ ha->max_rsp_queues = ha->msix_count - 1;
ha->msix_entries = kzalloc(sizeof(struct qla_msix_entry) *
ha->msix_count, GFP_KERNEL);
if (!ha->msix_entries) {
--
1.7.7.6

2014-04-14 08:15:09

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 20/23] pmcraid: Use pci_enable_msix_range() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Ravindranath <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/pmcraid.c | 13 ++-----------
1 files changed, 2 insertions(+), 11 deletions(-)

diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c
index c06af7f..6d0f208 100644
--- a/drivers/scsi/pmcraid.c
+++ b/drivers/scsi/pmcraid.c
@@ -4698,19 +4698,10 @@ pmcraid_register_interrupt_handler(struct pmcraid_instance *pinstance)
for (i = 0; i < PMCRAID_NUM_MSIX_VECTORS; i++)
entries[i].entry = i;

- rc = pci_enable_msix(pdev, entries, num_hrrq);
- if (rc < 0)
+ num_hrrq = pci_enable_msix_range(pdev, entries, 1, num_hrrq);
+ if (num_hrrq < 0)
goto pmcraid_isr_legacy;

- /* Check how many MSIX vectors are allocated and register
- * msi-x handlers for each of them giving appropriate buffer
- */
- if (rc > 0) {
- num_hrrq = rc;
- if (pci_enable_msix(pdev, entries, num_hrrq))
- goto pmcraid_isr_legacy;
- }
-
for (i = 0; i < num_hrrq; i++) {
pinstance->hrrq_vector[i].hrrq_id = i;
pinstance->hrrq_vector[i].drv_inst = pinstance;
--
1.7.7.6

2014-04-14 08:04:31

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 14/23] megaraid: Use pci_enable_msix_range() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Neela Syam Kolli <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/megaraid/megaraid_sas_base.c | 20 +++++++-------------
1 files changed, 7 insertions(+), 13 deletions(-)

diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c
index 2df717c..26f89d4 100644
--- a/drivers/scsi/megaraid/megaraid_sas_base.c
+++ b/drivers/scsi/megaraid/megaraid_sas_base.c
@@ -4106,17 +4106,11 @@ static int megasas_init_fw(struct megasas_instance *instance)
(unsigned int)num_online_cpus());
for (i = 0; i < instance->msix_vectors; i++)
instance->msixentry[i].entry = i;
- i = pci_enable_msix(instance->pdev, instance->msixentry,
- instance->msix_vectors);
- if (i >= 0) {
- if (i) {
- if (!pci_enable_msix(instance->pdev,
- instance->msixentry, i))
- instance->msix_vectors = i;
- else
- instance->msix_vectors = 0;
- }
- } else
+ i = pci_enable_msix_range(instance->pdev, instance->msixentry,
+ 1, instance->msix_vectors);
+ if (i)
+ instance->msix_vectors = i;
+ else
instance->msix_vectors = 0;

dev_info(&instance->pdev->dev, "[scsi%d]: FW supports"
@@ -5136,8 +5130,8 @@ megasas_resume(struct pci_dev *pdev)

/* Now re-enable MSI-X */
if (instance->msix_vectors &&
- pci_enable_msix(instance->pdev, instance->msixentry,
- instance->msix_vectors))
+ pci_enable_msix_exact(instance->pdev, instance->msixentry,
+ instance->msix_vectors))
goto fail_reenable_msix;

switch (instance->pdev->device) {
--
1.7.7.6

2014-04-14 08:04:26

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 13/23] megaraid: Fail resume if MSI-X re-initialization failed

Currently the driver fails to analize MSI-X re-enablement
status on resuming and always assumes the success. This
update checks the MSI-X initialization result and fails
to resume if MSI-Xs re-enablement failed.

Signed-off-by: Alexander Gordeev <[email protected]>
---
drivers/scsi/megaraid/megaraid_sas_base.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c
index d84d02c..2df717c 100644
--- a/drivers/scsi/megaraid/megaraid_sas_base.c
+++ b/drivers/scsi/megaraid/megaraid_sas_base.c
@@ -5135,9 +5135,10 @@ megasas_resume(struct pci_dev *pdev)
goto fail_ready_state;

/* Now re-enable MSI-X */
- if (instance->msix_vectors)
- pci_enable_msix(instance->pdev, instance->msixentry,
- instance->msix_vectors);
+ if (instance->msix_vectors &&
+ pci_enable_msix(instance->pdev, instance->msixentry,
+ instance->msix_vectors))
+ goto fail_reenable_msix;

switch (instance->pdev->device) {
case PCI_DEVICE_ID_LSI_FUSION:
@@ -5246,6 +5247,7 @@ fail_init_mfi:

fail_set_dma_mask:
fail_ready_state:
+fail_reenable_msix:

pci_disable_device(pdev);

--
1.7.7.6

2014-04-14 08:19:33

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 15/23] mpt2sas: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Nagalakshmi Nandigama <[email protected]>
Cc: Sreekanth Reddy <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/mpt2sas/mpt2sas_base.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/mpt2sas/mpt2sas_base.c b/drivers/scsi/mpt2sas/mpt2sas_base.c
index bde63f7..984b605 100644
--- a/drivers/scsi/mpt2sas/mpt2sas_base.c
+++ b/drivers/scsi/mpt2sas/mpt2sas_base.c
@@ -1432,10 +1432,10 @@ _base_enable_msix(struct MPT2SAS_ADAPTER *ioc)
for (i = 0, a = entries; i < ioc->reply_queue_count; i++, a++)
a->entry = i;

- r = pci_enable_msix(ioc->pdev, entries, ioc->reply_queue_count);
+ r = pci_enable_msix_exact(ioc->pdev, entries, ioc->reply_queue_count);
if (r) {
- dfailprintk(ioc, printk(MPT2SAS_INFO_FMT "pci_enable_msix "
- "failed (r=%d) !!!\n", ioc->name, r));
+ dfailprintk(ioc, printk(MPT2SAS_INFO_FMT
+ "pci_enable_msix_exact failed (r=%d) !!!\n", ioc->name, r));
kfree(entries);
goto try_ioapic;
}
--
1.7.7.6

2014-04-14 08:04:23

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 08/23] isci: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Lukasz Dorau <[email protected]>
Cc: Maciej Patelczyk <[email protected]>
Cc: Dave Jiang <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/isci/init.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/isci/init.c b/drivers/scsi/isci/init.c
index 695b34e..4198e45 100644
--- a/drivers/scsi/isci/init.c
+++ b/drivers/scsi/isci/init.c
@@ -356,7 +356,7 @@ static int isci_setup_interrupts(struct pci_dev *pdev)
for (i = 0; i < num_msix; i++)
pci_info->msix_entries[i].entry = i;

- err = pci_enable_msix(pdev, pci_info->msix_entries, num_msix);
+ err = pci_enable_msix_exact(pdev, pci_info->msix_entries, num_msix);
if (err)
goto intx;

--
1.7.7.6

2014-04-14 08:23:20

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 12/23] lpfc: Use pci_enable_msix_range() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: James Smart <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/lpfc/lpfc_init.c | 38 +++++++++++++++++---------------------
1 files changed, 17 insertions(+), 21 deletions(-)

diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c
index 7163f37..b109adc 100644
--- a/drivers/scsi/lpfc/lpfc_init.c
+++ b/drivers/scsi/lpfc/lpfc_init.c
@@ -8100,9 +8100,9 @@ lpfc_sli4_pci_mem_unset(struct lpfc_hba *phba)
* @phba: pointer to lpfc hba data structure.
*
* This routine is invoked to enable the MSI-X interrupt vectors to device
- * with SLI-3 interface specs. The kernel function pci_enable_msix() is
- * called to enable the MSI-X vectors. Note that pci_enable_msix(), once
- * invoked, enables either all or nothing, depending on the current
+ * with SLI-3 interface specs. The kernel function pci_enable_msix_exact()
+ * is called to enable the MSI-X vectors. Note that pci_enable_msix_exact(),
+ * once invoked, enables either all or nothing, depending on the current
* availability of PCI vector resources. The device driver is responsible
* for calling the individual request_irq() to register each MSI-X vector
* with a interrupt handler, which is done in this function. Note that
@@ -8126,8 +8126,8 @@ lpfc_sli_enable_msix(struct lpfc_hba *phba)
phba->msix_entries[i].entry = i;

/* Configure MSI-X capability structure */
- rc = pci_enable_msix(phba->pcidev, phba->msix_entries,
- ARRAY_SIZE(phba->msix_entries));
+ rc = pci_enable_msix_exact(phba->pcidev, phba->msix_entries,
+ ARRAY_SIZE(phba->msix_entries));
if (rc) {
lpfc_printf_log(phba, KERN_INFO, LOG_INIT,
"0420 PCI enable MSI-X failed (%d)\n", rc);
@@ -8664,15 +8664,13 @@ out:
* @phba: pointer to lpfc hba data structure.
*
* This routine is invoked to enable the MSI-X interrupt vectors to device
- * with SLI-4 interface spec. The kernel function pci_enable_msix() is called
- * to enable the MSI-X vectors. Note that pci_enable_msix(), once invoked,
- * enables either all or nothing, depending on the current availability of
- * PCI vector resources. The device driver is responsible for calling the
- * individual request_irq() to register each MSI-X vector with a interrupt
- * handler, which is done in this function. Note that later when device is
- * unloading, the driver should always call free_irq() on all MSI-X vectors
- * it has done request_irq() on before calling pci_disable_msix(). Failure
- * to do so results in a BUG_ON() and a device will be left with MSI-X
+ * with SLI-4 interface spec. The kernel function pci_enable_msix_range()
+ * is called to enable the MSI-X vectors. The device driver is responsible
+ * for calling the individual request_irq() to register each MSI-X vector
+ * with a interrupt handler, which is done in this function. Note that later
+ * when device is unloading, the driver should always call free_irq() on all
+ * MSI-X vectors it has done request_irq() on before calling pci_disable_msix()
+ * Failure to do so results in a BUG_ON() and a device will be left with MSI-X
* enabled and leaks its vectors.
*
* Return codes
@@ -8694,18 +8692,16 @@ lpfc_sli4_enable_msix(struct lpfc_hba *phba)
phba->sli4_hba.msix_entries[index].entry = index;
vectors++;
}
-enable_msix_vectors:
- rc = pci_enable_msix(phba->pcidev, phba->sli4_hba.msix_entries,
- vectors);
- if (rc > 1) {
- vectors = rc;
- goto enable_msix_vectors;
- } else if (rc) {
+
+ rc = pci_enable_msix_range(phba->pcidev, phba->sli4_hba.msix_entries,
+ 2, vectors);
+ if (rc < 0) {
lpfc_printf_log(phba, KERN_INFO, LOG_INIT,
"0484 PCI enable MSI-X failed (%d)\n", rc);
goto vec_fail_out;
}

+ vectors = rc;
/* Log MSI-X vector assignment */
for (index = 0; index < vectors; index++)
lpfc_printf_log(phba, KERN_INFO, LOG_INIT,
--
1.7.7.6

2014-04-14 08:24:31

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 11/23] lpfc: Remove superfluous call to pci_disable_msix()

There is no need to call pci_disable_msix() in case
the previous call to pci_enable_msix() failed

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: James Smart <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: James Smart <[email protected]>
---
drivers/scsi/lpfc/lpfc_init.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c
index 635eeb3..7163f37 100644
--- a/drivers/scsi/lpfc/lpfc_init.c
+++ b/drivers/scsi/lpfc/lpfc_init.c
@@ -8131,7 +8131,7 @@ lpfc_sli_enable_msix(struct lpfc_hba *phba)
if (rc) {
lpfc_printf_log(phba, KERN_INFO, LOG_INIT,
"0420 PCI enable MSI-X failed (%d)\n", rc);
- goto msi_fail_out;
+ goto vec_fail_out;
}
for (i = 0; i < LPFC_MSIX_VECTORS; i++)
lpfc_printf_log(phba, KERN_INFO, LOG_INIT,
@@ -8209,6 +8209,8 @@ irq_fail_out:
msi_fail_out:
/* Unconfigure MSI-X capability structure */
pci_disable_msix(phba->pcidev);
+
+vec_fail_out:
return rc;
}

@@ -8701,7 +8703,7 @@ enable_msix_vectors:
} else if (rc) {
lpfc_printf_log(phba, KERN_INFO, LOG_INIT,
"0484 PCI enable MSI-X failed (%d)\n", rc);
- goto msi_fail_out;
+ goto vec_fail_out;
}

/* Log MSI-X vector assignment */
@@ -8764,9 +8766,10 @@ cfg_fail_out:
&phba->sli4_hba.fcp_eq_hdl[index]);
}

-msi_fail_out:
/* Unconfigure MSI-X capability structure */
pci_disable_msix(phba->pcidev);
+
+vec_fail_out:
return rc;
}

--
1.7.7.6

2014-04-14 08:04:19

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 05/23] csiostor: Remove superfluous call to pci_disable_msix()

There is no need to call pci_disable_msix() in case
the previous call to pci_enable_msix() failed

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Naresh Kumar Inna <[email protected]>
Cc: Arvind Bhushan <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/csiostor/csio_isr.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/csiostor/csio_isr.c b/drivers/scsi/csiostor/csio_isr.c
index 7ee9777..91ba91d 100644
--- a/drivers/scsi/csiostor/csio_isr.c
+++ b/drivers/scsi/csiostor/csio_isr.c
@@ -529,10 +529,8 @@ csio_enable_msix(struct csio_hw *hw)
csio_reduce_sqsets(hw, cnt - extra);
}
} else {
- if (rv > 0) {
- pci_disable_msix(hw->pdev);
+ if (rv > 0)
csio_info(hw, "Not using MSI-X, remainder:%d\n", rv);
- }

kfree(entries);
return -ENOMEM;
--
1.7.7.6

2014-04-14 08:25:55

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 07/23] fnic: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Hiral Patel <[email protected]>
Cc: Suma Ramars <[email protected]>
Cc: Brian Uchino <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/fnic/fnic_isr.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/fnic/fnic_isr.c b/drivers/scsi/fnic/fnic_isr.c
index 7d9b54a..a0dd1b6 100644
--- a/drivers/scsi/fnic/fnic_isr.c
+++ b/drivers/scsi/fnic/fnic_isr.c
@@ -257,8 +257,8 @@ int fnic_set_intr_mode(struct fnic *fnic)
fnic->raw_wq_count >= m &&
fnic->wq_copy_count >= o &&
fnic->cq_count >= n + m + o) {
- if (!pci_enable_msix(fnic->pdev, fnic->msix_entry,
- n + m + o + 1)) {
+ if (!pci_enable_msix_exact(fnic->pdev, fnic->msix_entry,
+ n + m + o + 1)) {
fnic->rq_count = n;
fnic->raw_wq_count = m;
fnic->wq_copy_count = o;
--
1.7.7.6

2014-04-14 08:04:17

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 06/23] csiostor: Use pci_enable_msix_range() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Naresh Kumar Inna <[email protected]>
Cc: Arvind Bhushan <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/csiostor/csio_hw.h | 2 +-
drivers/scsi/csiostor/csio_isr.c | 22 +++++++++-------------
2 files changed, 10 insertions(+), 14 deletions(-)

diff --git a/drivers/scsi/csiostor/csio_hw.h b/drivers/scsi/csiostor/csio_hw.h
index 49b1daa..5db2d85 100644
--- a/drivers/scsi/csiostor/csio_hw.h
+++ b/drivers/scsi/csiostor/csio_hw.h
@@ -94,7 +94,7 @@ enum {
};

struct csio_msix_entries {
- unsigned short vector; /* Vector assigned by pci_enable_msix */
+ unsigned short vector; /* Assigned MSI-X vector */
void *dev_id; /* Priv object associated w/ this msix*/
char desc[24]; /* Description of this vector */
};
diff --git a/drivers/scsi/csiostor/csio_isr.c b/drivers/scsi/csiostor/csio_isr.c
index 91ba91d..a8c748a 100644
--- a/drivers/scsi/csiostor/csio_isr.c
+++ b/drivers/scsi/csiostor/csio_isr.c
@@ -499,7 +499,7 @@ csio_reduce_sqsets(struct csio_hw *hw, int cnt)
static int
csio_enable_msix(struct csio_hw *hw)
{
- int rv, i, j, k, n, min, cnt;
+ int i, j, k, n, min, cnt;
struct csio_msix_entries *entryp;
struct msix_entry *entries;
int extra = CSIO_EXTRA_VECS;
@@ -521,19 +521,15 @@ csio_enable_msix(struct csio_hw *hw)

csio_dbg(hw, "FW supp #niq:%d, trying %d msix's\n", hw->cfg_niq, cnt);

- while ((rv = pci_enable_msix(hw->pdev, entries, cnt)) >= min)
- cnt = rv;
- if (!rv) {
- if (cnt < (hw->num_sqsets + extra)) {
- csio_dbg(hw, "Reducing sqsets to %d\n", cnt - extra);
- csio_reduce_sqsets(hw, cnt - extra);
- }
- } else {
- if (rv > 0)
- csio_info(hw, "Not using MSI-X, remainder:%d\n", rv);
-
+ cnt = pci_enable_msix_range(hw->pdev, entries, min, cnt);
+ if (cnt < 0) {
kfree(entries);
- return -ENOMEM;
+ return cnt;
+ }
+
+ if (cnt < (hw->num_sqsets + extra)) {
+ csio_dbg(hw, "Reducing sqsets to %d\n", cnt - extra);
+ csio_reduce_sqsets(hw, cnt - extra);
}

/* Save off vectors */
--
1.7.7.6

2014-04-14 08:04:12

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 02/23] bfa: Do not call pci_enable_msix() after it failed once

Function pci_enable_msix() should not be called in case
it threw a negative errno from a previous call.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: Anil Gurumurthy <[email protected]>
---
drivers/scsi/bfa/bfad.c | 48 ++++++++++++++++++++++------------------------
1 files changed, 23 insertions(+), 25 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c
index cc0fbcd..972ff8d 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1235,33 +1235,31 @@ bfad_setup_intr(struct bfad_s *bfad)
(bfa_asic_id_cb(pdev->device) && !msix_disable_cb)) {

error = pci_enable_msix(bfad->pcidev, msix_entries, bfad->nvec);
- if (error) {
- /* In CT1 & CT2, try to allocate just one vector */
- if (bfa_asic_id_ctc(pdev->device)) {
- printk(KERN_WARNING "bfa %s: trying one msix "
- "vector failed to allocate %d[%d]\n",
- bfad->pci_name, bfad->nvec, error);
- bfad->nvec = 1;
- error = pci_enable_msix(bfad->pcidev,
+ /* In CT1 & CT2, try to allocate just one vector */
+ if (error > 0 && bfa_asic_id_ctc(pdev->device)) {
+ printk(KERN_WARNING "bfa %s: trying one msix "
+ "vector failed to allocate %d[%d]\n",
+ bfad->pci_name, bfad->nvec, error);
+ bfad->nvec = 1;
+ error = pci_enable_msix(bfad->pcidev,
msix_entries, bfad->nvec);
- }
+ }

- /*
- * Only error number of vector is available.
- * We don't have a mechanism to map multiple
- * interrupts into one vector, so even if we
- * can try to request less vectors, we don't
- * know how to associate interrupt events to
- * vectors. Linux doesn't duplicate vectors
- * in the MSIX table for this case.
- */
- if (error) {
- printk(KERN_WARNING "bfad%d: "
- "pci_enable_msix failed (%d), "
- "use line based.\n",
- bfad->inst_no, error);
- goto line_based;
- }
+ /*
+ * Only error number of vector is available.
+ * We don't have a mechanism to map multiple
+ * interrupts into one vector, so even if we
+ * can try to request less vectors, we don't
+ * know how to associate interrupt events to
+ * vectors. Linux doesn't duplicate vectors
+ * in the MSIX table for this case.
+ */
+ if (error) {
+ printk(KERN_WARNING "bfad%d: "
+ "pci_enable_msix failed (%d), "
+ "use line based.\n",
+ bfad->inst_no, error);
+ goto line_based;
}

/* Disable INTX in MSI-X mode */
--
1.7.7.6

2014-04-14 08:04:09

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 01/23] be2iscsi: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Jayamohan Kallickal <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: Jayamohan Kallickal <[email protected]>
---
drivers/scsi/be2iscsi/be_main.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/scsi/be2iscsi/be_main.c b/drivers/scsi/be2iscsi/be_main.c
index 0d82229..279b2f9 100644
--- a/drivers/scsi/be2iscsi/be_main.c
+++ b/drivers/scsi/be2iscsi/be_main.c
@@ -5282,12 +5282,10 @@ static void beiscsi_msix_enable(struct beiscsi_hba *phba)
for (i = 0; i <= phba->num_cpus; i++)
phba->msix_entries[i].entry = i;

- status = pci_enable_msix(phba->pcidev, phba->msix_entries,
- (phba->num_cpus + 1));
+ status = pci_enable_msix_exact(phba->pcidev, phba->msix_entries,
+ phba->num_cpus + 1);
if (!status)
phba->msix_enabled = true;
-
- return;
}

/*
--
1.7.7.6

2014-04-14 08:27:26

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 04/23] bfa: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers
using these two interfaces need to be updated to use the
new pci_enable_msi_range() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/bfa/bfad.c | 20 ++++++--------------
1 files changed, 6 insertions(+), 14 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c
index e7e4774..839c81c 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1234,29 +1234,21 @@ bfad_setup_intr(struct bfad_s *bfad)
if ((bfa_asic_id_ctc(pdev->device) && !msix_disable_ct) ||
(bfa_asic_id_cb(pdev->device) && !msix_disable_cb)) {

- error = pci_enable_msix(bfad->pcidev, msix_entries, bfad->nvec);
+ error = pci_enable_msix_exact(bfad->pcidev,
+ msix_entries, bfad->nvec);
/* In CT1 & CT2, try to allocate just one vector */
- if (error > 0 && bfa_asic_id_ctc(pdev->device)) {
+ if (error == -ENOSPC && bfa_asic_id_ctc(pdev->device)) {
printk(KERN_WARNING "bfa %s: trying one msix "
"vector failed to allocate %d[%d]\n",
bfad->pci_name, bfad->nvec, error);
bfad->nvec = 1;
- error = pci_enable_msix(bfad->pcidev,
- msix_entries, bfad->nvec);
+ error = pci_enable_msix_exact(bfad->pcidev,
+ msix_entries, 1);
}

- /*
- * Only error number of vector is available.
- * We don't have a mechanism to map multiple
- * interrupts into one vector, so even if we
- * can try to request less vectors, we don't
- * know how to associate interrupt events to
- * vectors. Linux doesn't duplicate vectors
- * in the MSIX table for this case.
- */
if (error) {
printk(KERN_WARNING "bfad%d: "
- "pci_enable_msix failed (%d), "
+ "pci_enable_msix_exact failed (%d), "
"use line based.\n",
bfad->inst_no, error);
goto line_based;
--
1.7.7.6

2014-04-14 08:33:10

by Alexander Gordeev

[permalink] [raw]
Subject: [PATCH v2 RESEND 03/23] bfa: Cleanup bfad_setup_intr() function

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: Anil Gurumurthy <[email protected]>
---
drivers/scsi/bfa/bfad.c | 18 ++++++++----------
1 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c
index 972ff8d..e7e4774 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1219,7 +1219,7 @@ bfad_install_msix_handler(struct bfad_s *bfad)
int
bfad_setup_intr(struct bfad_s *bfad)
{
- int error = 0;
+ int error;
u32 mask = 0, i, num_bit = 0, max_bit = 0;
struct msix_entry msix_entries[MAX_MSIX_ENTRY];
struct pci_dev *pdev = bfad->pcidev;
@@ -1279,20 +1279,18 @@ bfad_setup_intr(struct bfad_s *bfad)

bfad->bfad_flags |= BFAD_MSIX_ON;

- return error;
+ return 0;
}

line_based:
- error = 0;
- if (request_irq
- (bfad->pcidev->irq, (irq_handler_t) bfad_intx, BFAD_IRQ_FLAGS,
- BFAD_DRIVER_NAME, bfad) != 0) {
- /* Enable interrupt handler failed */
- return 1;
- }
+ error = request_irq(bfad->pcidev->irq, (irq_handler_t)bfad_intx,
+ BFAD_IRQ_FLAGS, BFAD_DRIVER_NAME, bfad);
+ if (error)
+ return error;
+
bfad->bfad_flags |= BFAD_INTX_ON;

- return error;
+ return 0;
}

void
--
1.7.7.6

2014-04-15 12:48:51

by Vikas Chaudhary

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 22/23] qla4xxx: Use pci_enable_msix_exact() instead of pci_enable_msix()



On 14/04/14 1:35 pm, "Alexander Gordeev" <[email protected]> wrote:

>As result of deprecation of MSI-X/MSI enablement functions
>pci_enable_msix() and pci_enable_msi_block() all drivers
>using these two interfaces need to be updated to use the
>new pci_enable_msi_range() or pci_enable_msi_exact()
>and pci_enable_msix_range() or pci_enable_msix_exact()
>interfaces.
>
>Signed-off-by: Alexander Gordeev <[email protected]>
>Cc: Vikas Chaudhary <[email protected]>
>Cc: [email protected]
>Cc: [email protected]
>Cc: [email protected]
>---
> drivers/scsi/qla4xxx/ql4_nx.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
>diff --git a/drivers/scsi/qla4xxx/ql4_nx.c b/drivers/scsi/qla4xxx/ql4_nx.c
>index 63328c8..a3e69e6 100644
>--- a/drivers/scsi/qla4xxx/ql4_nx.c
>+++ b/drivers/scsi/qla4xxx/ql4_nx.c
>@@ -3787,7 +3787,7 @@ qla4_8xxx_enable_msix(struct scsi_qla_host *ha)
> for (i = 0; i < QLA_MSIX_ENTRIES; i++)
> entries[i].entry = qla4_8xxx_msix_entries[i].entry;
>
>- ret = pci_enable_msix(ha->pdev, entries, ARRAY_SIZE(entries));
>+ ret = pci_enable_msix_exact(ha->pdev, entries, ARRAY_SIZE(entries));
> if (ret) {
> ql4_printk(KERN_WARNING, ha,
> "MSI-X: Failed to enable support -- %d/%d\n",
>--
>1.7.7.6

Acked-By: Vikas Chaudhary <[email protected]>

2014-04-16 12:12:31

by Anil Gurumurthy

[permalink] [raw]
Subject: RE: [PATCH v2 RESEND 03/23] bfa: Cleanup bfad_setup_intr() function

Patch look good.
Acked-by: Anil Gurumurthy <[email protected]>

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Alexander Gordeev
Sent: 14 April 2014 13:35
To: linux-kernel
Cc: Alexander Gordeev; Anil Gurumurthy; Vijaya Mohan Guvva; linux-scsi; linux-pci
Subject: [PATCH v2 RESEND 03/23] bfa: Cleanup bfad_setup_intr() function

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: Anil Gurumurthy <[email protected]>
---
drivers/scsi/bfa/bfad.c | 18 ++++++++----------
1 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c index 972ff8d..e7e4774 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1219,7 +1219,7 @@ bfad_install_msix_handler(struct bfad_s *bfad) int bfad_setup_intr(struct bfad_s *bfad) {
- int error = 0;
+ int error;
u32 mask = 0, i, num_bit = 0, max_bit = 0;
struct msix_entry msix_entries[MAX_MSIX_ENTRY];
struct pci_dev *pdev = bfad->pcidev;
@@ -1279,20 +1279,18 @@ bfad_setup_intr(struct bfad_s *bfad)

bfad->bfad_flags |= BFAD_MSIX_ON;

- return error;
+ return 0;
}

line_based:
- error = 0;
- if (request_irq
- (bfad->pcidev->irq, (irq_handler_t) bfad_intx, BFAD_IRQ_FLAGS,
- BFAD_DRIVER_NAME, bfad) != 0) {
- /* Enable interrupt handler failed */
- return 1;
- }
+ error = request_irq(bfad->pcidev->irq, (irq_handler_t)bfad_intx,
+ BFAD_IRQ_FLAGS, BFAD_DRIVER_NAME, bfad);
+ if (error)
+ return error;
+
bfad->bfad_flags |= BFAD_INTX_ON;

- return error;
+ return 0;
}

void
--
1.7.7.6

2014-04-16 12:12:45

by Anil Gurumurthy

[permalink] [raw]
Subject: RE: [PATCH v2 RESEND 02/23] bfa: Do not call pci_enable_msix() after it failed once

Patch look good.
Acked-by: Anil Gurumurthy <[email protected]>

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Alexander Gordeev
Sent: 14 April 2014 13:35
To: linux-kernel
Cc: Alexander Gordeev; Anil Gurumurthy; Vijaya Mohan Guvva; linux-scsi; linux-pci
Subject: [PATCH v2 RESEND 02/23] bfa: Do not call pci_enable_msix() after it failed once

Function pci_enable_msix() should not be called in case it threw a negative errno from a previous call.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: Anil Gurumurthy <[email protected]>
---
drivers/scsi/bfa/bfad.c | 48 ++++++++++++++++++++++------------------------
1 files changed, 23 insertions(+), 25 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c index cc0fbcd..972ff8d 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1235,33 +1235,31 @@ bfad_setup_intr(struct bfad_s *bfad)
(bfa_asic_id_cb(pdev->device) && !msix_disable_cb)) {

error = pci_enable_msix(bfad->pcidev, msix_entries, bfad->nvec);
- if (error) {
- /* In CT1 & CT2, try to allocate just one vector */
- if (bfa_asic_id_ctc(pdev->device)) {
- printk(KERN_WARNING "bfa %s: trying one msix "
- "vector failed to allocate %d[%d]\n",
- bfad->pci_name, bfad->nvec, error);
- bfad->nvec = 1;
- error = pci_enable_msix(bfad->pcidev,
+ /* In CT1 & CT2, try to allocate just one vector */
+ if (error > 0 && bfa_asic_id_ctc(pdev->device)) {
+ printk(KERN_WARNING "bfa %s: trying one msix "
+ "vector failed to allocate %d[%d]\n",
+ bfad->pci_name, bfad->nvec, error);
+ bfad->nvec = 1;
+ error = pci_enable_msix(bfad->pcidev,
msix_entries, bfad->nvec);
- }
+ }

- /*
- * Only error number of vector is available.
- * We don't have a mechanism to map multiple
- * interrupts into one vector, so even if we
- * can try to request less vectors, we don't
- * know how to associate interrupt events to
- * vectors. Linux doesn't duplicate vectors
- * in the MSIX table for this case.
- */
- if (error) {
- printk(KERN_WARNING "bfad%d: "
- "pci_enable_msix failed (%d), "
- "use line based.\n",
- bfad->inst_no, error);
- goto line_based;
- }
+ /*
+ * Only error number of vector is available.
+ * We don't have a mechanism to map multiple
+ * interrupts into one vector, so even if we
+ * can try to request less vectors, we don't
+ * know how to associate interrupt events to
+ * vectors. Linux doesn't duplicate vectors
+ * in the MSIX table for this case.
+ */
+ if (error) {
+ printk(KERN_WARNING "bfad%d: "
+ "pci_enable_msix failed (%d), "
+ "use line based.\n",
+ bfad->inst_no, error);
+ goto line_based;
}

/* Disable INTX in MSI-X mode */
--
1.7.7.6

2014-04-16 12:13:03

by Anil Gurumurthy

[permalink] [raw]
Subject: RE: [PATCH v2 RESEND 04/23] bfa: Use pci_enable_msix_exact() instead of pci_enable_msix()

Patch look good.
Acked-by: Anil Gurumurthy <[email protected]>

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Alexander Gordeev
Sent: 14 April 2014 13:35
To: linux-kernel
Cc: Alexander Gordeev; Anil Gurumurthy; Vijaya Mohan Guvva; linux-scsi; linux-pci
Subject: [PATCH v2 RESEND 04/23] bfa: Use pci_enable_msix_exact() instead of pci_enable_msix()

As result of deprecation of MSI-X/MSI enablement functions
pci_enable_msix() and pci_enable_msi_block() all drivers using these two interfaces need to be updated to use the new pci_enable_msi_range() or pci_enable_msi_exact() and pci_enable_msix_range() or pci_enable_msix_exact() interfaces.

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
---
drivers/scsi/bfa/bfad.c | 20 ++++++--------------
1 files changed, 6 insertions(+), 14 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c index e7e4774..839c81c 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1234,29 +1234,21 @@ bfad_setup_intr(struct bfad_s *bfad)
if ((bfa_asic_id_ctc(pdev->device) && !msix_disable_ct) ||
(bfa_asic_id_cb(pdev->device) && !msix_disable_cb)) {

- error = pci_enable_msix(bfad->pcidev, msix_entries, bfad->nvec);
+ error = pci_enable_msix_exact(bfad->pcidev,
+ msix_entries, bfad->nvec);
/* In CT1 & CT2, try to allocate just one vector */
- if (error > 0 && bfa_asic_id_ctc(pdev->device)) {
+ if (error == -ENOSPC && bfa_asic_id_ctc(pdev->device)) {
printk(KERN_WARNING "bfa %s: trying one msix "
"vector failed to allocate %d[%d]\n",
bfad->pci_name, bfad->nvec, error);
bfad->nvec = 1;
- error = pci_enable_msix(bfad->pcidev,
- msix_entries, bfad->nvec);
+ error = pci_enable_msix_exact(bfad->pcidev,
+ msix_entries, 1);
}

- /*
- * Only error number of vector is available.
- * We don't have a mechanism to map multiple
- * interrupts into one vector, so even if we
- * can try to request less vectors, we don't
- * know how to associate interrupt events to
- * vectors. Linux doesn't duplicate vectors
- * in the MSIX table for this case.
- */
if (error) {
printk(KERN_WARNING "bfad%d: "
- "pci_enable_msix failed (%d), "
+ "pci_enable_msix_exact failed (%d), "
"use line based.\n",
bfad->inst_no, error);
goto line_based;
--
1.7.7.6

2014-04-16 12:13:28

by Anil Gurumurthy

[permalink] [raw]
Subject: RE: [PATCH v2 RESEND 03/23] bfa: Cleanup bfad_setup_intr() function

Patch look good.
Acked-by: Anil Gurumurthy <[email protected]>

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Alexander Gordeev
Sent: 14 April 2014 13:35
To: linux-kernel
Cc: Alexander Gordeev; Anil Gurumurthy; Vijaya Mohan Guvva; linux-scsi; linux-pci
Subject: [PATCH v2 RESEND 03/23] bfa: Cleanup bfad_setup_intr() function

Signed-off-by: Alexander Gordeev <[email protected]>
Cc: Anil Gurumurthy <[email protected]>
Cc: Vijaya Mohan Guvva <[email protected]>
Cc: [email protected]
Cc: [email protected]
Acked-by: Anil Gurumurthy <[email protected]>
---
drivers/scsi/bfa/bfad.c | 18 ++++++++----------
1 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c index 972ff8d..e7e4774 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -1219,7 +1219,7 @@ bfad_install_msix_handler(struct bfad_s *bfad) int bfad_setup_intr(struct bfad_s *bfad) {
- int error = 0;
+ int error;
u32 mask = 0, i, num_bit = 0, max_bit = 0;
struct msix_entry msix_entries[MAX_MSIX_ENTRY];
struct pci_dev *pdev = bfad->pcidev;
@@ -1279,20 +1279,18 @@ bfad_setup_intr(struct bfad_s *bfad)

bfad->bfad_flags |= BFAD_MSIX_ON;

- return error;
+ return 0;
}

line_based:
- error = 0;
- if (request_irq
- (bfad->pcidev->irq, (irq_handler_t) bfad_intx, BFAD_IRQ_FLAGS,
- BFAD_DRIVER_NAME, bfad) != 0) {
- /* Enable interrupt handler failed */
- return 1;
- }
+ error = request_irq(bfad->pcidev->irq, (irq_handler_t)bfad_intx,
+ BFAD_IRQ_FLAGS, BFAD_DRIVER_NAME, bfad);
+ if (error)
+ return error;
+
bfad->bfad_flags |= BFAD_INTX_ON;

- return error;
+ return 0;
}

void
--
1.7.7.6

2014-04-16 12:54:17

by Artur Paszkiewicz

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 08/23] isci: Use pci_enable_msix_exact() instead of pci_enable_msix()

On 04/14/2014 10:05 AM, Alexander Gordeev wrote:
> As result of deprecation of MSI-X/MSI enablement functions
> pci_enable_msix() and pci_enable_msi_block() all drivers
> using these two interfaces need to be updated to use the
> new pci_enable_msi_range() or pci_enable_msi_exact()
> and pci_enable_msix_range() or pci_enable_msix_exact()
> interfaces.
>
> Signed-off-by: Alexander Gordeev <[email protected]>
> Cc: Lukasz Dorau <[email protected]>
> Cc: Maciej Patelczyk <[email protected]>
> Cc: Dave Jiang <[email protected]>
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> ---
> drivers/scsi/isci/init.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/scsi/isci/init.c b/drivers/scsi/isci/init.c
> index 695b34e..4198e45 100644
> --- a/drivers/scsi/isci/init.c
> +++ b/drivers/scsi/isci/init.c
> @@ -356,7 +356,7 @@ static int isci_setup_interrupts(struct pci_dev *pdev)
> for (i = 0; i < num_msix; i++)
> pci_info->msix_entries[i].entry = i;
>
> - err = pci_enable_msix(pdev, pci_info->msix_entries, num_msix);
> + err = pci_enable_msix_exact(pdev, pci_info->msix_entries, num_msix);
> if (err)
> goto intx;
>
>

Looks good.

Acked-by: Artur Paszkiewicz <[email protected]>

Thanks,
Artur

2014-04-24 17:09:15

by Bjorn Helgaas

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 00/23] scsi: Use pci_enable_msix_range() instead of pci_enable_msix()

On Mon, Apr 14, 2014 at 10:05:24AM +0200, Alexander Gordeev wrote:
> Hello,
>
> This series is against 3.15-rc1.
>
> As result of deprecation of MSI-X/MSI enablement functions
> pci_enable_msix() and pci_enable_msi_block() all drivers
> using these two interfaces need to be updated to use the
> new pci_enable_msi_range() or pci_enable_msi_exact()
> and pci_enable_msix_range() or pci_enable_msix_exact()
> interfaces.

Hi James,

These depend on f7fc32c, which appeared in v3.15-rc1. I had intended
to merge these scsi updates at the same time, but I failed. Would you
like to take them now that f7fc32c is upstream?

If not, I'd still be glad to do it, but it might avoid some conflicts
if you took them.

Bjorn

> There are no major changes in this series since I posted
> it last time.
>
> Thanks!
>
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
> Cc: [email protected]
>
>
> Alexander Gordeev (23):
> be2iscsi: Use pci_enable_msix_exact() instead of pci_enable_msix()
> bfa: Do not call pci_enable_msix() after it failed once
> bfa: Cleanup bfad_setup_intr() function
> bfa: Use pci_enable_msix_exact() instead of pci_enable_msix()
> csiostor: Remove superfluous call to pci_disable_msix()
> csiostor: Use pci_enable_msix_range() instead of pci_enable_msix()
> fnic: Use pci_enable_msix_exact() instead of pci_enable_msix()
> isci: Use pci_enable_msix_exact() instead of pci_enable_msix()
> hpsa: Fallback to MSI rather than to INTx if MSI-X failed
> hpsa: Use pci_enable_msix_range() instead of pci_enable_msix()
> lpfc: Remove superfluous call to pci_disable_msix()
> lpfc: Use pci_enable_msix_range() instead of pci_enable_msix()
> megaraid: Fail resume if MSI-X re-initialization failed
> megaraid: Use pci_enable_msix_range() instead of pci_enable_msix()
> mpt2sas: Use pci_enable_msix_exact() instead of pci_enable_msix()
> mpt3sas: Use pci_enable_msix_exact() instead of pci_enable_msix()
> pm8001: Fix invalid return when request_irq() failed
> pm8001: Use pci_enable_msix_exact() instead of pci_enable_msix()
> pmcraid: Get rid of a redundant assignment
> pmcraid: Use pci_enable_msix_range() instead of pci_enable_msix()
> qla2xxx: Use pci_enable_msix_range() instead of pci_enable_msix()
> qla4xxx: Use pci_enable_msix_exact() instead of pci_enable_msix()
> vmw_pvscsi: Use pci_enable_msix_exact() instead of pci_enable_msix()
>
> drivers/scsi/be2iscsi/be_main.c | 6 +--
> drivers/scsi/bfa/bfad.c | 62 ++++++++++++-----------------
> drivers/scsi/csiostor/csio_hw.h | 2 +-
> drivers/scsi/csiostor/csio_isr.c | 24 ++++-------
> drivers/scsi/fnic/fnic_isr.c | 4 +-
> drivers/scsi/hpsa.c | 30 ++++++--------
> drivers/scsi/isci/init.c | 2 +-
> drivers/scsi/lpfc/lpfc_init.c | 47 +++++++++++-----------
> drivers/scsi/megaraid/megaraid_sas_base.c | 24 +++++------
> drivers/scsi/mpt2sas/mpt2sas_base.c | 6 +-
> drivers/scsi/mpt3sas/mpt3sas_base.c | 4 +-
> drivers/scsi/pm8001/pm8001_init.c | 44 +++++++++++----------
> drivers/scsi/pmcraid.c | 14 +------
> drivers/scsi/qla2xxx/qla_isr.c | 27 +++++-------
> drivers/scsi/qla4xxx/ql4_nx.c | 2 +-
> drivers/scsi/vmw_pvscsi.c | 2 +-
> 16 files changed, 129 insertions(+), 171 deletions(-)
>
> --
> 1.7.7.6
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/

2014-04-24 17:51:36

by James Bottomley

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 00/23] scsi: Use pci_enable_msix_range() instead of pci_enable_msix()

On Thu, 2014-04-24 at 11:09 -0600, Bjorn Helgaas wrote:
> On Mon, Apr 14, 2014 at 10:05:24AM +0200, Alexander Gordeev wrote:
> > Hello,
> >
> > This series is against 3.15-rc1.
> >
> > As result of deprecation of MSI-X/MSI enablement functions
> > pci_enable_msix() and pci_enable_msi_block() all drivers
> > using these two interfaces need to be updated to use the
> > new pci_enable_msi_range() or pci_enable_msi_exact()
> > and pci_enable_msix_range() or pci_enable_msix_exact()
> > interfaces.
>
> Hi James,
>
> These depend on f7fc32c, which appeared in v3.15-rc1. I had intended
> to merge these scsi updates at the same time, but I failed. Would you
> like to take them now that f7fc32c is upstream?

OK, will add them. I'm planning to base the scsi-misc tree on -rc3 once
we have our current crop of fixes upstream.

James

2014-04-24 18:07:35

by Bjorn Helgaas

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 00/23] scsi: Use pci_enable_msix_range() instead of pci_enable_msix()

On Thu, Apr 24, 2014 at 11:51 AM, James Bottomley
<[email protected]> wrote:
> On Thu, 2014-04-24 at 11:09 -0600, Bjorn Helgaas wrote:
>> On Mon, Apr 14, 2014 at 10:05:24AM +0200, Alexander Gordeev wrote:
>> > Hello,
>> >
>> > This series is against 3.15-rc1.
>> >
>> > As result of deprecation of MSI-X/MSI enablement functions
>> > pci_enable_msix() and pci_enable_msi_block() all drivers
>> > using these two interfaces need to be updated to use the
>> > new pci_enable_msi_range() or pci_enable_msi_exact()
>> > and pci_enable_msix_range() or pci_enable_msix_exact()
>> > interfaces.
>>
>> Hi James,
>>
>> These depend on f7fc32c, which appeared in v3.15-rc1. I had intended
>> to merge these scsi updates at the same time, but I failed. Would you
>> like to take them now that f7fc32c is upstream?
>
> OK, will add them. I'm planning to base the scsi-misc tree on -rc3 once
> we have our current crop of fixes upstream.

Great, thanks!

Bjorn

2014-06-16 07:34:57

by Alexander Gordeev

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 00/23] scsi: Use pci_enable_msix_range() instead of pci_enable_msix()

On Thu, Apr 24, 2014 at 05:51:09PM +0000, James Bottomley wrote:
> > These depend on f7fc32c, which appeared in v3.15-rc1. I had intended
> > to merge these scsi updates at the same time, but I failed. Would you
> > like to take them now that f7fc32c is upstream?
>
> OK, will add them. I'm planning to base the scsi-misc tree on -rc3 once
> we have our current crop of fixes upstream.

Hi James,

If I need to repost the series to get it into you tree?

Thanks!

> James
>

--
Regards,
Alexander Gordeev
[email protected]

2014-07-07 18:34:32

by Alexander Gordeev

[permalink] [raw]
Subject: Re: [PATCH v2 RESEND 00/23] scsi: Use pci_enable_msix_range() instead of pci_enable_msix()

On Thu, Apr 24, 2014 at 12:07:12PM -0600, Bjorn Helgaas wrote:
> >> These depend on f7fc32c, which appeared in v3.15-rc1. I had intended
> >> to merge these scsi updates at the same time, but I failed. Would you
> >> like to take them now that f7fc32c is upstream?
> >
> > OK, will add them. I'm planning to base the scsi-misc tree on -rc3 once
> > we have our current crop of fixes upstream.
>
> Great, thanks!

James, Bjorn,

All patches except 'be2iscsi' (patch 1) and 'hpsa' (patches 9,10) still
apply. Would you take those apply or have me resend all of them or just
'be2iscsi' and 'hpsa'?

Thanks!

> Bjorn

--
Regards,
Alexander Gordeev
[email protected]