Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 292871
b: refs/heads/master
c: 187e70a
h: refs/heads/master
i:
  292869: d9b1e56
  292867: f2758e1
  292863: 44970fd
v: v3
  • Loading branch information
Nicholas Bellinger committed Mar 18, 2012
1 parent aee4304 commit d1c4e0d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ee9b866a3696ae434418348e2f499c41841366d4
refs/heads/master: 187e70a554e0f0717a65998bc9199945cbbd4692
19 changes: 12 additions & 7 deletions trunk/drivers/infiniband/ulp/srpt/ib_srpt.c
Original file line number Diff line number Diff line change
Expand Up @@ -1757,22 +1757,27 @@ static int srpt_handle_cmd(struct srpt_rdma_ch *ch,
srp_cmd->tag);
cmd->se_cmd_flags |= SCF_SCSI_CDB_EXCEPTION;
cmd->scsi_sense_reason = TCM_INVALID_CDB_FIELD;
kref_put(&send_ioctx->kref, srpt_put_send_ioctx_kref);
goto send_sense;
}

cmd->data_length = data_len;
cmd->data_direction = dir;
unpacked_lun = srpt_unpack_lun((uint8_t *)&srp_cmd->lun,
sizeof(srp_cmd->lun));
if (transport_lookup_cmd_lun(cmd, unpacked_lun) < 0)
if (transport_lookup_cmd_lun(cmd, unpacked_lun) < 0) {
kref_put(&send_ioctx->kref, srpt_put_send_ioctx_kref);
goto send_sense;
}
ret = transport_generic_allocate_tasks(cmd, srp_cmd->cdb);
if (cmd->se_cmd_flags & SCF_SCSI_RESERVATION_CONFLICT)
srpt_queue_status(cmd);
else if (cmd->se_cmd_flags & SCF_SCSI_CDB_EXCEPTION)
goto send_sense;
else
WARN_ON_ONCE(ret);
if (ret < 0) {
kref_put(&send_ioctx->kref, srpt_put_send_ioctx_kref);
if (cmd->se_cmd_flags & SCF_SCSI_RESERVATION_CONFLICT) {
srpt_queue_status(cmd);
return 0;
} else
goto send_sense;
}

transport_handle_cdb_direct(cmd);
return 0;
Expand Down

0 comments on commit d1c4e0d

Please sign in to comment.