From: Geliang Tang Date: Thu, 14 Jan 2016 23:22:01 +0000 (-0800) Subject: mm: move lru_to_page to mm_inline.h X-Git-Tag: v4.5-rc1~94^2~12 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=d72ee911130631b50a8ccc615a7d4622c2062194;p=linux-block.git mm: move lru_to_page to mm_inline.h Move lru_to_page() from internal.h to mm_inline.h. Signed-off-by: Geliang Tang Acked-by: Vlastimil Babka Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/include/linux/mm_inline.h b/include/linux/mm_inline.h index cf55945c83fb..712e8c37a200 100644 --- a/include/linux/mm_inline.h +++ b/include/linux/mm_inline.h @@ -100,4 +100,6 @@ static __always_inline enum lru_list page_lru(struct page *page) return lru; } +#define lru_to_page(head) (list_entry((head)->prev, struct page, lru)) + #endif diff --git a/mm/internal.h b/mm/internal.h index 016452d2fede..38e24b89e4c4 100644 --- a/mm/internal.h +++ b/mm/internal.h @@ -119,8 +119,6 @@ extern int isolate_lru_page(struct page *page); extern void putback_lru_page(struct page *page); extern bool zone_reclaimable(struct zone *zone); -#define lru_to_page(_head) (list_entry((_head)->prev, struct page, lru)) - /* * in mm/rmap.c: */ diff --git a/mm/readahead.c b/mm/readahead.c index 0aff760b09d4..20e58e820e44 100644 --- a/mm/readahead.c +++ b/mm/readahead.c @@ -17,6 +17,7 @@ #include #include #include +#include #include "internal.h"