aboutsummaryrefslogtreecommitdiff
path: root/drivers/scsi/bfa
diff options
context:
space:
mode:
authorJing Xiangfeng2020-09-25 14:24:23 +0800
committerMartin K. Petersen2020-10-07 23:50:04 -0400
commitf0f6c3a4fcb80fcbcce4ff6739996dd98c228afd (patch)
treec10f7310f0f919f0ed21ec9605a5aa65c6e980e6 /drivers/scsi/bfa
parentde6c063fa09a671cce7bea996cfe2a9288f794a8 (diff)
scsi: bfa: Fix error return in bfad_pci_init()
Fix to return error code -ENODEV from the error handling case instead of 0. Link: https://lore.kernel.org/r/20200925062423.161504-1-jingxiangfeng@huawei.com Fixes: 11ea3824140c ("scsi: bfa: fix calls to dma_set_mask_and_coherent()") Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/bfa')
-rw-r--r--drivers/scsi/bfa/bfad.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c
index bc5d84f87d8f..440ef32be048 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -749,6 +749,7 @@ bfad_pci_init(struct pci_dev *pdev, struct bfad_s *bfad)
if (bfad->pci_bar0_kva == NULL) {
printk(KERN_ERR "Fail to map bar0\n");
+ rc = -ENODEV;
goto out_release_region;
}