Commit bc7f84c0 authored by Fabian Frederick's avatar Fabian Frederick Committed by Linus Torvalds

mm/internal.h: use nth_page

Use nth_page instead of pfn_to_page(page_to_pfn
Signed-off-by: default avatarFabian Frederick <fabf@skynet.be>
Cc: Rik van Riel <riel@redhat.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 7be12fc9
......@@ -247,7 +247,7 @@ static inline void mlock_migrate_page(struct page *new, struct page *old) { }
static inline struct page *mem_map_offset(struct page *base, int offset)
{
if (unlikely(offset >= MAX_ORDER_NR_PAGES))
return pfn_to_page(page_to_pfn(base) + offset);
return nth_page(base, offset);
return base + offset;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment