Lines Matching defs:se_cmd

763 	u32 iov_count = (cmd->se_cmd.t_data_nents == 0) ? 1 :
764 cmd->se_cmd.t_data_nents;
781 u32 length = cmd->se_cmd.data_length;
817 transport_generic_map_mem_to_cmd(&cmd->se_cmd, sgl, nents, NULL, 0);
820 * so that cmd->se_cmd.t_tasks_se_num has been set.
1012 if (cmd->se_cmd.scsi_sense_reason == TCM_NON_EXISTENT_LUN) {
1026 transport_ret = transport_generic_allocate_tasks(&cmd->se_cmd, hdr->cdb);
1039 cmd->data_length = cmd->se_cmd.data_length;
1055 core_alua_check_nonop_delay(&cmd->se_cmd);
1119 ret = transport_generic_new_cmd(&cmd->se_cmd);
1244 struct se_cmd *se_cmd;
1304 se_cmd = &cmd->se_cmd;
1321 transport_send_check_condition_and_sense(&cmd->se_cmd,
1332 spin_lock_irqsave(&se_cmd->t_state_lock, flags);
1333 WARN_ON(se_cmd->t_state != TRANSPORT_WRITE_PENDING);
1334 spin_unlock_irqrestore(&se_cmd->t_state_lock, flags);
1336 spin_lock_irqsave(&se_cmd->t_state_lock, flags);
1337 if (!(se_cmd->se_cmd_flags & SCF_SUPPORTED_SAM_OPCODE) ||
1338 (se_cmd->se_cmd_flags & SCF_SCSI_CDB_EXCEPTION))
1340 spin_unlock_irqrestore(&se_cmd->t_state_lock, flags);
1351 transport_check_aborted_status(se_cmd,
1366 if (atomic_read(&se_cmd->t_transport_aborted) != 0) {
1371 se_cmd, 1);
1460 &cmd->se_cmd) : 0;
1743 se_tmr = cmd->se_cmd.se_tmr_req;
1752 cmd->se_cmd.se_cmd_flags |= SCF_SCSI_CDB_EXCEPTION;
1762 cmd->se_cmd.se_cmd_flags |= SCF_SCSI_CDB_EXCEPTION;
1773 cmd->se_cmd.se_cmd_flags |= SCF_SCSI_CDB_EXCEPTION;
1780 cmd->se_cmd.se_cmd_flags |= SCF_SCSI_CDB_EXCEPTION;
1802 cmd->se_cmd.se_cmd_flags |= SCF_SCSI_CDB_EXCEPTION;
1834 return transport_generic_handle_tmr(&cmd->se_cmd);
2490 (cmd->se_cmd.se_cmd_flags & SCF_TRANSPORT_TASK_SENSE))
2508 if (cmd->se_cmd.se_cmd_flags & SCF_OVERFLOW_BIT) {
2510 hdr->residual_count = cpu_to_be32(cmd->se_cmd.residual_count);
2511 } else if (cmd->se_cmd.se_cmd_flags & SCF_UNDERFLOW_BIT) {
2513 hdr->residual_count = cpu_to_be32(cmd->se_cmd.residual_count);
2518 int_to_scsilun(cmd->se_cmd.orig_fe_lun,
2590 *eodr = (cmd->se_cmd.se_cmd_flags & SCF_TRANSPORT_TASK_SENSE) ?
2865 int_to_scsilun(cmd->se_cmd.orig_fe_lun,
3013 if (cmd->se_cmd.se_cmd_flags & SCF_OVERFLOW_BIT) {
3015 hdr->residual_count = cpu_to_be32(cmd->se_cmd.residual_count);
3016 } else if (cmd->se_cmd.se_cmd_flags & SCF_UNDERFLOW_BIT) {
3018 hdr->residual_count = cpu_to_be32(cmd->se_cmd.residual_count);
3021 hdr->cmd_status = cmd->se_cmd.scsi_status;
3037 if (cmd->se_cmd.sense_buffer &&
3038 ((cmd->se_cmd.se_cmd_flags & SCF_TRANSPORT_TASK_SENSE) ||
3039 (cmd->se_cmd.se_cmd_flags & SCF_EMULATED_TASK_SENSE))) {
3040 padding = -(cmd->se_cmd.scsi_sense_length) & 3;
3041 hton24(hdr->dlength, cmd->se_cmd.scsi_sense_length);
3042 iov[iov_count].iov_base = cmd->se_cmd.sense_buffer;
3044 (cmd->se_cmd.scsi_sense_length + padding);
3045 tx_size += cmd->se_cmd.scsi_sense_length;
3048 memset(cmd->se_cmd.sense_buffer +
3049 cmd->se_cmd.scsi_sense_length, 0, padding);
3057 cmd->se_cmd.sense_buffer,
3058 (cmd->se_cmd.scsi_sense_length + padding),
3067 (cmd->se_cmd.scsi_sense_length + padding),
3073 cmd->se_cmd.scsi_sense_length);
3095 cmd->stat_sn, 0x00, cmd->se_cmd.scsi_status, conn->cid);
3123 struct se_tmr_req *se_tmr = cmd->se_cmd.se_tmr_req;
3516 struct se_cmd *se_cmd;
3699 se_cmd = &cmd->se_cmd;