[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
@@ -86,8 +86,7 @@ int rotate_reclaimable_page(struct page *page)
|
||||
zone = page_zone(page);
|
||||
spin_lock_irqsave(&zone->lru_lock, flags);
|
||||
if (PageLRU(page) && !PageActive(page)) {
|
||||
list_del(&page->lru);
|
||||
list_add_tail(&page->lru, &zone->inactive_list);
|
||||
list_move_tail(&page->lru, &zone->inactive_list);
|
||||
inc_page_state(pgrotated);
|
||||
}
|
||||
if (!test_clear_page_writeback(page))
|
||||
|
Reference in New Issue
Block a user