Commit 785fdf70 authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Nicholas Bellinger

target: simplify command to task linkage

Now that we only have a single task per command we can use a direct pointer
to it instead of list.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarNicholas Bellinger <nab@linux-iscsi.org>
parent 4101f0a8
......@@ -321,13 +321,11 @@ static void core_tmr_drain_task_list(
cmd->se_tfo->get_cmd_state(cmd), cmd->t_state,
cmd->t_task_cdb[0]);
pr_debug("LUN_RESET: ITT[0x%08x] - pr_res_key: 0x%016Lx"
" t_task_cdbs: %d t_task_cdbs_left: %d"
" t_task_cdbs_sent: %d -- CMD_T_ACTIVE: %d"
" t_task_cdbs_left: %d"
" -- CMD_T_ACTIVE: %d"
" CMD_T_STOP: %d CMD_T_SENT: %d\n",
cmd->se_tfo->get_task_tag(cmd), cmd->pr_res_key,
cmd->t_task_list_num,
atomic_read(&cmd->t_task_cdbs_left),
atomic_read(&cmd->t_task_cdbs_sent),
(cmd->transport_state & CMD_T_ACTIVE) != 0,
(cmd->transport_state & CMD_T_STOP) != 0,
(cmd->transport_state & CMD_T_SENT) != 0);
......
This diff is collapsed.
......@@ -492,7 +492,6 @@ struct se_task {
u16 task_flags;
u8 task_scsi_status;
enum dma_data_direction task_data_direction;
struct list_head t_list;
struct list_head t_execute_list;
struct list_head t_state_list;
bool t_state_active;
......@@ -573,7 +572,6 @@ struct se_cmd {
atomic_t t_se_count;
atomic_t t_task_cdbs_left;
atomic_t t_task_cdbs_ex_left;
atomic_t t_task_cdbs_sent;
unsigned int transport_state;
#define CMD_T_ABORTED (1 << 0)
#define CMD_T_ACTIVE (1 << 1)
......@@ -598,10 +596,7 @@ struct se_cmd {
struct scatterlist *t_bidi_data_sg;
unsigned int t_bidi_data_nents;
/* Used for BIDI READ */
struct list_head t_task_list;
u32 t_task_list_num;
struct se_task *t_task;
};
struct se_ua {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment