aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla4xxx
diff options
context:
space:
mode:
authorMike Christie <michaelc@cs.wisc.edu>2011-12-01 22:38:43 -0500
committerJames Bottomley <JBottomley@Parallels.com>2011-12-14 06:40:44 -0500
commitff1d0319ac6a5fd859884b30c0a3cb6733b8fb2d (patch)
tree70fc663a5440f4eb613d94d23c76b3186c824b66 /drivers/scsi/qla4xxx
parente1cd89c507b41e4021ce6fb0d19d230f6a932ccd (diff)
[SCSI] qla4xxx: check for failed conn setup
iscsi_conn_setup can fail so we must check for NULL being returned. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/qla4xxx')
-rw-r--r--drivers/scsi/qla4xxx/ql4_os.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index 95910c9b4776..4169c8baa112 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -1207,6 +1207,9 @@ qla4xxx_conn_create(struct iscsi_cls_session *cls_sess, uint32_t conn_idx)
1207 DEBUG2(printk(KERN_INFO "Func: %s\n", __func__)); 1207 DEBUG2(printk(KERN_INFO "Func: %s\n", __func__));
1208 cls_conn = iscsi_conn_setup(cls_sess, sizeof(struct qla_conn), 1208 cls_conn = iscsi_conn_setup(cls_sess, sizeof(struct qla_conn),
1209 conn_idx); 1209 conn_idx);
1210 if (!cls_conn)
1211 return NULL;
1212
1210 sess = cls_sess->dd_data; 1213 sess = cls_sess->dd_data;
1211 ddb_entry = sess->dd_data; 1214 ddb_entry = sess->dd_data;
1212 ddb_entry->conn = cls_conn; 1215 ddb_entry->conn = cls_conn;