Lines Matching refs:se_cmd
49 struct se_cmd *se_cmd; in _ft_dump_cmd() local
53 se_cmd = &cmd->se_cmd; in _ft_dump_cmd()
55 caller, cmd, cmd->sess, cmd->seq, se_cmd); in _ft_dump_cmd()
58 caller, cmd, se_cmd->t_data_nents, in _ft_dump_cmd()
59 se_cmd->data_length, se_cmd->se_cmd_flags); in _ft_dump_cmd()
61 for_each_sg(se_cmd->t_data_sg, sg, se_cmd->t_data_nents, count) in _ft_dump_cmd()
97 percpu_ida_free(&sess->se_sess->sess_tag_pool, cmd->se_cmd.map_tag); in ft_free_cmd()
101 void ft_release_cmd(struct se_cmd *se_cmd) in ft_release_cmd() argument
103 struct ft_cmd *cmd = container_of(se_cmd, struct ft_cmd, se_cmd); in ft_release_cmd()
108 int ft_check_stop_free(struct se_cmd *se_cmd) in ft_check_stop_free() argument
110 return transport_generic_free_cmd(se_cmd, 0); in ft_check_stop_free()
116 int ft_queue_status(struct se_cmd *se_cmd) in ft_queue_status() argument
118 struct ft_cmd *cmd = container_of(se_cmd, struct ft_cmd, se_cmd); in ft_queue_status()
131 len = sizeof(*fcp) + se_cmd->scsi_sense_length; in ft_queue_status()
134 se_cmd->scsi_status = SAM_STAT_TASK_SET_FULL; in ft_queue_status()
140 fcp->resp.fr_status = se_cmd->scsi_status; in ft_queue_status()
142 len = se_cmd->scsi_sense_length; in ft_queue_status()
146 memcpy((fcp + 1), se_cmd->sense_buffer, len); in ft_queue_status()
153 if (se_cmd->se_cmd_flags & (SCF_OVERFLOW_BIT | SCF_UNDERFLOW_BIT)) { in ft_queue_status()
154 if (se_cmd->se_cmd_flags & SCF_OVERFLOW_BIT) in ft_queue_status()
158 fcp->ext.fr_resid = cpu_to_be32(se_cmd->residual_count); in ft_queue_status()
177 se_cmd->scsi_status = SAM_STAT_TASK_SET_FULL; in ft_queue_status()
186 target_put_sess_cmd(&cmd->se_cmd); in ft_queue_status()
190 int ft_write_pending_status(struct se_cmd *se_cmd) in ft_write_pending_status() argument
192 struct ft_cmd *cmd = container_of(se_cmd, struct ft_cmd, se_cmd); in ft_write_pending_status()
194 return cmd->write_data_len != se_cmd->data_length; in ft_write_pending_status()
200 int ft_write_pending(struct se_cmd *se_cmd) in ft_write_pending() argument
202 struct ft_cmd *cmd = container_of(se_cmd, struct ft_cmd, se_cmd); in ft_write_pending()
222 txrdy->ft_burst_len = htonl(se_cmd->data_length); in ft_write_pending()
238 if ((se_cmd->se_cmd_flags & SCF_SCSI_DATA_CDB) && in ft_write_pending()
240 se_cmd->t_data_sg, in ft_write_pending()
241 se_cmd->t_data_nents)) in ft_write_pending()
249 int ft_get_cmd_state(struct se_cmd *se_cmd) in ft_get_cmd_state() argument
283 transport_generic_free_cmd(&cmd->se_cmd, 0); in ft_recv_seq()
393 rc = target_submit_tmr(&cmd->se_cmd, cmd->sess->se_sess, in ft_send_tm()
403 void ft_queue_tm_resp(struct se_cmd *se_cmd) in ft_queue_tm_resp() argument
405 struct ft_cmd *cmd = container_of(se_cmd, struct ft_cmd, se_cmd); in ft_queue_tm_resp()
406 struct se_tmr_req *tmr = se_cmd->se_tmr_req; in ft_queue_tm_resp()
435 target_put_sess_cmd(&cmd->se_cmd); in ft_queue_tm_resp()
438 void ft_aborted_task(struct se_cmd *se_cmd) in ft_aborted_task() argument
462 cmd->se_cmd.map_tag = tag; in ft_recv_cmd()
567 cmd->se_cmd.tag = fc_seq_exch(cmd->seq)->rxid; in ft_send_work()
572 if (target_submit_cmd(&cmd->se_cmd, cmd->sess->se_sess, fcp->fc_cdb, in ft_send_work()