|
@@ -1113,6 +1113,7 @@ void transport_init_se_cmd(
|
|
init_completion(&cmd->cmd_wait_comp);
|
|
init_completion(&cmd->cmd_wait_comp);
|
|
init_completion(&cmd->task_stop_comp);
|
|
init_completion(&cmd->task_stop_comp);
|
|
spin_lock_init(&cmd->t_state_lock);
|
|
spin_lock_init(&cmd->t_state_lock);
|
|
|
|
+ kref_init(&cmd->cmd_kref);
|
|
cmd->transport_state = CMD_T_DEV_ACTIVE;
|
|
cmd->transport_state = CMD_T_DEV_ACTIVE;
|
|
|
|
|
|
cmd->se_tfo = tfo;
|
|
cmd->se_tfo = tfo;
|
|
@@ -2357,7 +2358,6 @@ int target_get_sess_cmd(struct se_session *se_sess, struct se_cmd *se_cmd,
|
|
unsigned long flags;
|
|
unsigned long flags;
|
|
int ret = 0;
|
|
int ret = 0;
|
|
|
|
|
|
- kref_init(&se_cmd->cmd_kref);
|
|
|
|
/*
|
|
/*
|
|
* Add a second kref if the fabric caller is expecting to handle
|
|
* Add a second kref if the fabric caller is expecting to handle
|
|
* fabric acknowledgement that requires two target_put_sess_cmd()
|
|
* fabric acknowledgement that requires two target_put_sess_cmd()
|