diff options
Diffstat (limited to 'mm/page_alloc.c')
-rw-r--r-- | mm/page_alloc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 8246e834b2f0..c5caac2c3c5a 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c | |||
@@ -495,7 +495,6 @@ static void __free_pages_ok(struct page *page, unsigned int order) | |||
495 | int i; | 495 | int i; |
496 | int reserved = 0; | 496 | int reserved = 0; |
497 | 497 | ||
498 | arch_free_page(page, order); | ||
499 | if (!PageHighMem(page)) | 498 | if (!PageHighMem(page)) |
500 | debug_check_no_locks_freed(page_address(page), | 499 | debug_check_no_locks_freed(page_address(page), |
501 | PAGE_SIZE<<order); | 500 | PAGE_SIZE<<order); |
@@ -505,7 +504,9 @@ static void __free_pages_ok(struct page *page, unsigned int order) | |||
505 | if (reserved) | 504 | if (reserved) |
506 | return; | 505 | return; |
507 | 506 | ||
507 | arch_free_page(page, order); | ||
508 | kernel_map_pages(page, 1 << order, 0); | 508 | kernel_map_pages(page, 1 << order, 0); |
509 | |||
509 | local_irq_save(flags); | 510 | local_irq_save(flags); |
510 | __count_vm_events(PGFREE, 1 << order); | 511 | __count_vm_events(PGFREE, 1 << order); |
511 | free_one_page(page_zone(page), page, order); | 512 | free_one_page(page_zone(page), page, order); |
@@ -781,13 +782,12 @@ static void fastcall free_hot_cold_page(struct page *page, int cold) | |||
781 | struct per_cpu_pages *pcp; | 782 | struct per_cpu_pages *pcp; |
782 | unsigned long flags; | 783 | unsigned long flags; |
783 | 784 | ||
784 | arch_free_page(page, 0); | ||
785 | |||
786 | if (PageAnon(page)) | 785 | if (PageAnon(page)) |
787 | page->mapping = NULL; | 786 | page->mapping = NULL; |
788 | if (free_pages_check(page)) | 787 | if (free_pages_check(page)) |
789 | return; | 788 | return; |
790 | 789 | ||
790 | arch_free_page(page, 0); | ||
791 | kernel_map_pages(page, 1, 0); | 791 | kernel_map_pages(page, 1, 0); |
792 | 792 | ||
793 | pcp = &zone_pcp(zone, get_cpu())->pcp[cold]; | 793 | pcp = &zone_pcp(zone, get_cpu())->pcp[cold]; |