<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">
This needs to be merged up to the correct place in the tree.

Signed-off-by: Dave Hansen &lt;haveblue@us.ibm.com&gt;
---

 memhotplug-dave/mm/page_alloc.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletion(-)

diff -puN mm/page_alloc.c~K4-swap_remove_compilefixes mm/page_alloc.c
--- memhotplug/mm/page_alloc.c~K4-swap_remove_compilefixes	2004-12-08 14:57:22.000000000 -0800
+++ memhotplug-dave/mm/page_alloc.c	2004-12-08 14:57:22.000000000 -0800
@@ -374,6 +374,8 @@ static inline void capture_pages(struct 
 		clear_page_under_capture(&amp;page[i]);
 	page_zone(page)-&gt;present_pages -= (1UL &lt;&lt; order);
 	totalram_pages -= (1UL &lt;&lt; order);
+	if (PageHighMem(page))
+		totalhigh_pages -= (1UL &lt;&lt; order);
 }
 
 static inline int test_remove_range(struct page *page, struct page *base,
@@ -630,6 +632,9 @@ int is_head_of_free_region(struct page *
 	spin_unlock_irqrestore(&amp;zone-&gt;lock, flags);
         return 0;
 }
+#endif /* CONFIG_PM */
+
+#if defined(CONFIG_PM) || defined(CONFIG_MEMORY_HOTPLUG)
 
 /*
  * Spill all of this CPU's per-cpu pages back into the buddy allocator.
@@ -642,7 +647,7 @@ void drain_local_pages(void)
 	__drain_pages(smp_processor_id());
 	local_irq_restore(flags);	
 }
-#endif /* CONFIG_PM */
+#endif /* CONFIG_PM  || CONFIG_MEMORY_HOTPLUG */
 
 #ifdef CONFIG_MEMORY_HOTPLUG
 static inline int first_uncaptured_page(unsigned long start_pfn, int nr_pages)
_
</pre></body></html>