Skip to content

Commit

Permalink
target: lock => unlock typo in transport_lun_wait_for_tasks
Browse files Browse the repository at this point in the history
target_stop_cmd() returns with the lock held and IRQs disabled.  The
intent was to unlock here.  This bug was originally added with:

commit cf572a9
Author: Christoph Hellwig <hch@infradead.org>
Date:   Tue Apr 24 00:25:05 2012 -0400

    target: move the state and execute lists to the command

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
  • Loading branch information
Dan Carpenter authored and Nicholas Bellinger committed May 9, 2012
1 parent 7b4deef commit 2301917
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/target/target_core_transport.c
Original file line number Diff line number Diff line change
Expand Up @@ -3768,7 +3768,7 @@ static int transport_lun_wait_for_tasks(struct se_cmd *cmd, struct se_lun *lun)
(cmd->transport_state & CMD_T_SENT)) {
if (!target_stop_cmd(cmd, &flags))
ret++;
spin_lock_irqsave(&cmd->t_state_lock, flags);
spin_unlock_irqrestore(&cmd->t_state_lock, flags);
} else {
spin_unlock_irqrestore(&cmd->t_state_lock,
flags);
Expand Down

0 comments on commit 2301917

Please sign in to comment.