mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-01 08:46:36 +09:00
target: Prevent TRANSPORT_FREE_CMD_INTR processing in core_tmr_drain_cmd_list
commit b0e062aec5 upstream.
This patch contains a bugfix for TMR LUN_RESET related to TRANSPORT_FREE_CMD_INTR
operation, where core_tmr_drain_cmd_list() will now skip processing for this
case to prevent an ABORT_TASK status from being returned for descriptors that
are already queued up to be released by processing thread context.
Cc: Roland Dreier <roland@purestorage.com>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Nicholas Bellinger <nab@risingtidesystems.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
6f47552250
commit
be9f40a767
@@ -337,6 +337,16 @@ int core_tmr_lun_reset(
|
||||
*/
|
||||
if (prout_cmd == cmd)
|
||||
continue;
|
||||
/*
|
||||
* Skip direct processing of TRANSPORT_FREE_CMD_INTR for
|
||||
* HW target mode fabrics.
|
||||
*/
|
||||
spin_lock(&cmd->t_state_lock);
|
||||
if (cmd->t_state == TRANSPORT_FREE_CMD_INTR) {
|
||||
spin_unlock(&cmd->t_state_lock);
|
||||
continue;
|
||||
}
|
||||
spin_unlock(&cmd->t_state_lock);
|
||||
|
||||
atomic_dec(&cmd->t_transport_queue_active);
|
||||
atomic_dec(&qobj->queue_cnt);
|
||||
|
||||
Reference in New Issue
Block a user