summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/be2iscsi
diff options
context:
space:
mode:
authorDan Carpenter <error27@gmail.com>2010-06-10 09:53:05 +0200
committerJames Bottomley <James.Bottomley@suse.de>2010-07-27 12:01:41 -0500
commit82284c09c5dc5c5a5046f3c852f2683dab60109c (patch)
treeaaafb7f4401fc980efe13affa29212971a0a6702 /drivers/scsi/be2iscsi
parent1462b8ffd9a9e4798d4e0f9eaadbd1ac0373a11b (diff)
downloadlinux-82284c09c5dc5c5a5046f3c852f2683dab60109c.tar.bz2
[SCSI] be2iscsi: fix null dereference on error path
"phba" is always null here so we can't dereference it. Signed-off-by: Dan Carpenter <error27@gmail.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/be2iscsi')
-rw-r--r--drivers/scsi/be2iscsi/be_main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/be2iscsi/be_main.c b/drivers/scsi/be2iscsi/be_main.c
index 353a90b3574d..0d35bf6c6acc 100644
--- a/drivers/scsi/be2iscsi/be_main.c
+++ b/drivers/scsi/be2iscsi/be_main.c
@@ -3774,8 +3774,8 @@ static int __devinit beiscsi_dev_probe(struct pci_dev *pcidev,
ret = beiscsi_enable_pci(pcidev);
if (ret < 0) {
- shost_printk(KERN_ERR, phba->shost, "beiscsi_dev_probe-"
- "Failed to enable pci device \n");
+ dev_err(&pcidev->dev, "beiscsi_dev_probe-"
+ " Failed to enable pci device\n");
return ret;
}