[PATCH] core: use list_move()
This patch converts the combination of list_del(A) and list_add(A, B) to list_move(A, B). Cc: Greg Kroah-Hartman <gregkh@suse.de> Cc: Ram Pai <linuxram@us.ibm.com> Signed-off-by: Akinobu Mita <mita@miraclelinux.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
a7addcea6a
commit
1bfba4e8ea
@@ -526,10 +526,8 @@ void umount_tree(struct vfsmount *mnt, int propagate, struct list_head *kill)
|
||||
{
|
||||
struct vfsmount *p;
|
||||
|
||||
for (p = mnt; p; p = next_mnt(p, mnt)) {
|
||||
list_del(&p->mnt_hash);
|
||||
list_add(&p->mnt_hash, kill);
|
||||
}
|
||||
for (p = mnt; p; p = next_mnt(p, mnt))
|
||||
list_move(&p->mnt_hash, kill);
|
||||
|
||||
if (propagate)
|
||||
propagate_umount(kill);
|
||||
|
Reference in New Issue
Block a user