diff options
-rw-r--r-- | drivers/scsi/qla2xxx/qla_bsg.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/scsi/qla2xxx/qla_bsg.c b/drivers/scsi/qla2xxx/qla_bsg.c index ffcad26af968..fb5bd6e17e8a 100644 --- a/drivers/scsi/qla2xxx/qla_bsg.c +++ b/drivers/scsi/qla2xxx/qla_bsg.c | |||
@@ -1266,6 +1266,7 @@ qla24xx_iidma(struct fc_bsg_job *bsg_job) | |||
1266 | int rval = 0; | 1266 | int rval = 0; |
1267 | struct qla_port_param *port_param = NULL; | 1267 | struct qla_port_param *port_param = NULL; |
1268 | fc_port_t *fcport = NULL; | 1268 | fc_port_t *fcport = NULL; |
1269 | int found = 0; | ||
1269 | uint16_t mb[MAILBOX_REGISTER_COUNT]; | 1270 | uint16_t mb[MAILBOX_REGISTER_COUNT]; |
1270 | uint8_t *rsp_ptr = NULL; | 1271 | uint8_t *rsp_ptr = NULL; |
1271 | 1272 | ||
@@ -1288,10 +1289,12 @@ qla24xx_iidma(struct fc_bsg_job *bsg_job) | |||
1288 | if (memcmp(port_param->fc_scsi_addr.dest_addr.wwpn, | 1289 | if (memcmp(port_param->fc_scsi_addr.dest_addr.wwpn, |
1289 | fcport->port_name, sizeof(fcport->port_name))) | 1290 | fcport->port_name, sizeof(fcport->port_name))) |
1290 | continue; | 1291 | continue; |
1292 | |||
1293 | found = 1; | ||
1291 | break; | 1294 | break; |
1292 | } | 1295 | } |
1293 | 1296 | ||
1294 | if (!fcport) { | 1297 | if (!found) { |
1295 | ql_log(ql_log_warn, vha, 0x7049, | 1298 | ql_log(ql_log_warn, vha, 0x7049, |
1296 | "Failed to find port.\n"); | 1299 | "Failed to find port.\n"); |
1297 | return -EINVAL; | 1300 | return -EINVAL; |