summaryrefslogtreecommitdiff
path: root/drivers/scsi/scsi_tgt_lib.c
diff options
context:
space:
mode:
authorKirill A. Shutemov <kirill@shutemov.name>2011-04-02 03:06:09 +0400
committerJames Bottomley <James.Bottomley@suse.de>2011-05-01 19:20:10 +0400
commit63ce2499947683dcc026373e24a4cb5a9d086e7d (patch)
treeabafb4f3a79e8c7a7a3af9901a966942f4bd181a /drivers/scsi/scsi_tgt_lib.c
parent38b34aca30ef1296bbc552505d80c69f274f0872 (diff)
downloadlinux-63ce2499947683dcc026373e24a4cb5a9d086e7d.tar.xz
[SCSI] esp, scsi_tgt_lib, fcoe: use list_move() instead of list_del()/list_add() combination
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name> Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
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 8bca8c25ba69..84a1fdf67864 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);