Lines Matching defs:se_cmd

46 static int tcm_loop_queue_status(struct se_cmd *se_cmd);
60 static int tcm_loop_check_stop_free(struct se_cmd *se_cmd)
62 return transport_generic_free_cmd(se_cmd, 0);
65 static void tcm_loop_release_cmd(struct se_cmd *se_cmd)
67 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
71 if (se_cmd->se_cmd_flags & SCF_SCSI_TMR_CDB)
103 struct se_cmd *se_cmd = &tl_cmd->tl_se_cmd;
137 se_cmd->prot_pto = true;
146 se_cmd->tag = tl_cmd->sc_cmd_tag;
147 target_init_cmd(se_cmd, tl_nexus->se_sess, &tl_cmd->tl_sense_buf[0],
151 if (target_submit_prep(se_cmd, sc->cmnd, scsi_sglist(sc),
157 target_submit(se_cmd);
192 struct se_cmd *se_cmd;
213 se_cmd = &tl_cmd->tl_se_cmd;
216 rc = target_submit_tmr(se_cmd, se_sess, tl_cmd->tl_sense_buf, lun,
222 ret = se_cmd->se_tmr_req->response;
223 target_put_sess_cmd(se_cmd);
488 static int tcm_loop_get_cmd_state(struct se_cmd *se_cmd)
490 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
496 static int tcm_loop_write_pending(struct se_cmd *se_cmd)
501 * memory, and memory has already been mapped to struct se_cmd->t_mem_list
507 target_execute_cmd(se_cmd);
512 struct se_cmd *se_cmd, u8 scsi_status)
514 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
521 if (se_cmd->sense_buffer &&
522 ((se_cmd->se_cmd_flags & SCF_TRANSPORT_TASK_SENSE) ||
523 (se_cmd->se_cmd_flags & SCF_EMULATED_TASK_SENSE))) {
525 memcpy(sc->sense_buffer, se_cmd->sense_buffer,
532 if ((se_cmd->se_cmd_flags & SCF_OVERFLOW_BIT) ||
533 (se_cmd->se_cmd_flags & SCF_UNDERFLOW_BIT))
534 scsi_set_resid(sc, se_cmd->residual_count);
538 static int tcm_loop_queue_data_in(struct se_cmd *se_cmd)
540 return tcm_loop_queue_data_or_status(__func__, se_cmd, SAM_STAT_GOOD);
543 static int tcm_loop_queue_status(struct se_cmd *se_cmd)
546 se_cmd, se_cmd->scsi_status);
549 static void tcm_loop_queue_tm_rsp(struct se_cmd *se_cmd)
551 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
558 static void tcm_loop_aborted_task(struct se_cmd *se_cmd)