diff options
author | Jiang Liu <liuj97@gmail.com> | 2013-04-29 18:07:05 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-29 18:54:32 -0400 |
commit | a564496e2cf9ea37a553d27c8ca4cef78015b2e2 (patch) | |
tree | f3dfab389d273115f21db54d79a00ac9e7bb59de /arch/metag | |
parent | 8b2888c756450ffece7a37e0f3ee49353015e5dd (diff) |
mm/metag: use free_highmem_page() to free highmem pages into buddy system
Use helper function free_highmem_page() to free highmem pages into
the buddy system.
Signed-off-by: Jiang Liu <jiang.liu@huawei.com>
Cc: James Hogan <james.hogan@imgtec.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/metag')
-rw-r--r-- | arch/metag/mm/init.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/arch/metag/mm/init.c b/arch/metag/mm/init.c index c6784fb3a334..d05b8455c44c 100644 --- a/arch/metag/mm/init.c +++ b/arch/metag/mm/init.c | |||
@@ -380,14 +380,8 @@ void __init mem_init(void) | |||
380 | 380 | ||
381 | #ifdef CONFIG_HIGHMEM | 381 | #ifdef CONFIG_HIGHMEM |
382 | unsigned long tmp; | 382 | unsigned long tmp; |
383 | for (tmp = highstart_pfn; tmp < highend_pfn; tmp++) { | 383 | for (tmp = highstart_pfn; tmp < highend_pfn; tmp++) |
384 | struct page *page = pfn_to_page(tmp); | 384 | free_highmem_page(pfn_to_page(tmp)); |
385 | ClearPageReserved(page); | ||
386 | init_page_count(page); | ||
387 | __free_page(page); | ||
388 | totalhigh_pages++; | ||
389 | } | ||
390 | totalram_pages += totalhigh_pages; | ||
391 | num_physpages += totalhigh_pages; | 385 | num_physpages += totalhigh_pages; |
392 | #endif /* CONFIG_HIGHMEM */ | 386 | #endif /* CONFIG_HIGHMEM */ |
393 | 387 | ||