Signed-off-by: Dave Hansen --- memhotplug-dave/mm/page_alloc.c | 16 +++++----------- 1 files changed, 5 insertions(+), 11 deletions(-) diff -puN mm/page_alloc.c~K6-capture-pages-cleanup mm/page_alloc.c --- memhotplug/mm/page_alloc.c~K6-capture-pages-cleanup 2005-07-28 13:51:13.000000000 -0700 +++ memhotplug-dave/mm/page_alloc.c 2005-07-28 13:51:13.000000000 -0700 @@ -791,13 +791,9 @@ int capture_page_range(unsigned long sta int fup; struct page *page; int i; - unsigned long nr_pages; + unsigned long nr_pages = 1<= 0) { - if (i++ < 100) - while (shrink_all_memory(10000)); - msleep(100); + while((fup = first_uncaptured_page(fup, nr_pages - (fup - start_pfn))) >= 0) { + while (shrink_all_memory(10000)); + msleep(1000); } return 0; _