[PATCH 9/9] free memory is user reclaimable

Joel Schopp
2005-09-26T20:17:27Z

[-- Attachment #1: Type: text/plain, Size: 239 bytes --]

Make the free memory revert to user reclaimable type, which is probably more
accurate, and certainly helpful for memory hotplug remove.

Signed-off-by: Mike Kravetz <kravetz@us.ibm.com>
Signed-off-by: Joel Schopp <jschopp@austin.ibm.com>

[-- Attachment #2: 9_free_memory_is_user --]
[-- Type: text/plain, Size: 941 bytes --]

Index: 2.6.13-joel2/mm/page_alloc.c
===================================================================
--- 2.6.13-joel2.orig/mm/page_alloc.c 2005-09-21 11:31:51.%N -0500
+++ 2.6.13-joel2/mm/page_alloc.c 2005-09-21 11:37:48.%N -0500
@@ -339,6 +339,9 @@ static inline int page_is_buddy(struct p
* triggers coalescing into a block of larger size.
*
* -- wli
+ *
+ * For hotplug memory purposes make the free memory revert to the user
+ * reclaimable type, which is probably more accurate for that state anyway.
*/

static inline void __free_pages_bulk (struct page *page,
@@ -379,7 +382,10 @@ static inline void __free_pages_bulk (st
page_idx = combined_idx;
order++;
}
- if (unlikely(order == MAX_ORDER-1)) zone->fallback_balance++;
+ if (unlikely(order == MAX_ORDER-1)) {
+ set_pageblock_type(zone, page, RCLM_USER);
+ zone->fallback_balance++;
+ }

set_page_order(page, order);
area = freelist + order;