summaryrefslogtreecommitdiff
path: root/drivers/scsi/qedf
diff options
context:
space:
mode:
authorSaurav Kashyap <skashyap@marvell.com>2020-04-16 01:43:14 -0700
committerMartin K. Petersen <martin.petersen@oracle.com>2020-04-17 17:55:29 -0400
commit7109cb51517267ef0631da293d80a26f4e18d3ba (patch)
treebee9daee3988ae28c87456db54d0da20e82e432c /drivers/scsi/qedf
parentad40f5256095c68dc17c991eb976261d5ea2daaa (diff)
scsi: qedf: Get dev info after updating the params
An update to pf params can change the devinfo. Get updated device information. [mkp: updated error message spotted by Sergei Shtylyov] Link: https://lore.kernel.org/r/20200416084314.18851-10-skashyap@marvell.com Signed-off-by: Saurav Kashyap <skashyap@marvell.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/qedf')
-rw-r--r--drivers/scsi/qedf/qedf_main.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/scsi/qedf/qedf_main.c b/drivers/scsi/qedf/qedf_main.c
index e7ddb5651261..36b1ca2dadbb 100644
--- a/drivers/scsi/qedf/qedf_main.c
+++ b/drivers/scsi/qedf/qedf_main.c
@@ -3324,6 +3324,13 @@ static int __qedf_probe(struct pci_dev *pdev, int mode)
}
qed_ops->common->update_pf_params(qedf->cdev, &qedf->pf_params);
+ /* Learn information crucial for qedf to progress */
+ rc = qed_ops->fill_dev_info(qedf->cdev, &qedf->dev_info);
+ if (rc) {
+ QEDF_ERR(&qedf->dbg_ctx, "Failed to fill dev info.\n");
+ goto err2;
+ }
+
/* Record BDQ producer doorbell addresses */
qedf->bdq_primary_prod = qedf->dev_info.primary_dbq_rq_addr;
qedf->bdq_secondary_prod = qedf->dev_info.secondary_bdq_rq_addr;