aboutsummaryrefslogtreecommitdiff
path: root/drivers/scsi/scsi_tgt_lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/scsi_tgt_lib.c')
-rw-r--r--drivers/scsi/scsi_tgt_lib.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/scsi/scsi_tgt_lib.c b/drivers/scsi/scsi_tgt_lib.c
index 8bca8c25ba6..84a1fdf6786 100644
--- a/drivers/scsi/scsi_tgt_lib.c
+++ b/drivers/scsi/scsi_tgt_lib.c
@@ -275,10 +275,8 @@ void scsi_tgt_free_queue(struct Scsi_Host *shost)
for (i = 0; i < ARRAY_SIZE(qdata->cmd_hash); i++) {
list_for_each_entry_safe(tcmd, n, &qdata->cmd_hash[i],
- hash_list) {
- list_del(&tcmd->hash_list);
- list_add(&tcmd->hash_list, &cmds);
- }
+ hash_list)
+ list_move(&tcmd->hash_list, &cmds);
}
spin_unlock_irqrestore(&qdata->cmd_hash_lock, flags);