Lines Matching defs:tl_cmd
67 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
69 struct scsi_cmnd *sc = tl_cmd->sc;
72 kmem_cache_free(tcm_loop_cmd_cache, tl_cmd);
101 static void tcm_loop_target_queue_cmd(struct tcm_loop_cmd *tl_cmd)
103 struct se_cmd *se_cmd = &tl_cmd->tl_se_cmd;
104 struct scsi_cmnd *sc = tl_cmd->sc;
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],
148 tl_cmd->sc->device->lun, transfer_length,
170 struct tcm_loop_cmd *tl_cmd = scsi_cmd_priv(sc);
177 memset(tl_cmd, 0, sizeof(*tl_cmd));
178 tl_cmd->sc = sc;
179 tl_cmd->sc_cmd_tag = scsi_cmd_to_rq(sc)->tag;
181 tcm_loop_target_queue_cmd(tl_cmd);
195 struct tcm_loop_cmd *tl_cmd;
207 tl_cmd = kmem_cache_zalloc(tcm_loop_cmd_cache, GFP_KERNEL);
208 if (!tl_cmd)
211 init_completion(&tl_cmd->tmr_done);
213 se_cmd = &tl_cmd->tl_se_cmd;
216 rc = target_submit_tmr(se_cmd, se_sess, tl_cmd->tl_sense_buf, lun,
221 wait_for_completion(&tl_cmd->tmr_done);
229 kmem_cache_free(tcm_loop_cmd_cache, tl_cmd);
490 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
493 return tl_cmd->sc_cmd_state;
514 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
516 struct scsi_cmnd *sc = tl_cmd->sc;
551 struct tcm_loop_cmd *tl_cmd = container_of(se_cmd,
555 complete(&tl_cmd->tmr_done);