diff options
author | Christoph Lameter <clameter@engr.sgi.com> | 2005-06-22 23:26:07 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-22 23:42:32 -0400 |
commit | b7c84c6ada2be942eca6722edb2cfaad412cd5de (patch) | |
tree | 06cba21e92755bf6b815221d5124ca0f9faf7985 | |
parent | a4936044001694f033fe4ea94d6034d51a6b465c (diff) |
[PATCH] boot_pageset must not be freed.
The boot_pageset needs to be preserved for hotplugging and for off line
processors and nodes. Otherwise pointers will point into memory that has
now a different use. /proc/zoneinfo is currently showing strange results
if processors / nodes are not present.
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | mm/page_alloc.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 206920796f5f..559336de9687 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c | |||
@@ -1742,10 +1742,17 @@ inline void setup_pageset(struct per_cpu_pageset *p, unsigned long batch) | |||
1742 | * with interrupts disabled. | 1742 | * with interrupts disabled. |
1743 | * | 1743 | * |
1744 | * Some NUMA counter updates may also be caught by the boot pagesets. | 1744 | * Some NUMA counter updates may also be caught by the boot pagesets. |
1745 | * These will be discarded when bootup is complete. | 1745 | * |
1746 | * The boot_pagesets must be kept even after bootup is complete for | ||
1747 | * unused processors and/or zones. They do play a role for bootstrapping | ||
1748 | * hotplugged processors. | ||
1749 | * | ||
1750 | * zoneinfo_show() and maybe other functions do | ||
1751 | * not check if the processor is online before following the pageset pointer. | ||
1752 | * Other parts of the kernel may not check if the zone is available. | ||
1746 | */ | 1753 | */ |
1747 | static struct per_cpu_pageset | 1754 | static struct per_cpu_pageset |
1748 | boot_pageset[NR_CPUS] __initdata; | 1755 | boot_pageset[NR_CPUS]; |
1749 | 1756 | ||
1750 | /* | 1757 | /* |
1751 | * Dynamically allocate memory for the | 1758 | * Dynamically allocate memory for the |