mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [2/9] NUMA-Q: memset pgdats later in boot
@ 2002-11-12  2:20 William Lee Irwin III
  0 siblings, 0 replies; only message in thread
From: William Lee Irwin III @ 2002-11-12  2:20 UTC (permalink / raw)
  To: linux-kernel

In order to remove the assumption that pgdats for nodes > 0 are mapped
early, this patch moves the process of memset()'ing a node's pgdat into
zone_sizes_init(), just before they're to be linked.

 discontig.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletion(-)


diff -urpN 00_late_list/arch/i386/mm/discontig.c 01_late_memset/arch/i386/mm/discontig.c
--- 00_late_list/arch/i386/mm/discontig.c	2002-11-11 16:13:57.000000000 -0800
+++ 01_late_memset/arch/i386/mm/discontig.c	2002-11-11 16:21:37.000000000 -0800
@@ -70,7 +70,8 @@ static void __init allocate_pgdat(int ni
 	node_datasz = PFN_UP(sizeof(struct pglist_data));
 	NODE_DATA(nid) = (pg_data_t *)(__va(min_low_pfn << PAGE_SHIFT));
 	min_low_pfn += node_datasz;
-	memset(NODE_DATA(nid), 0, sizeof(struct pglist_data));
+	if (!nid)
+		memset(NODE_DATA(nid), 0, sizeof(pg_data_t));
 }
 
 /*
@@ -281,6 +282,8 @@ void __init zone_sizes_init(void)
 	 */
 	pgdat_list = NULL;
 	for (nid = numnodes - 1; nid >= 0; nid--) {       
+		if (nid)
+			memset(NODE_DATA(nid), 0, sizeof(pg_data_t));
 		NODE_DATA(nid)->pgdat_next = pgdat_list;
 		pgdat_list = NODE_DATA(nid);
 	}

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-11-12  2:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-11-12  2:20 [2/9] NUMA-Q: memset pgdats later in boot William Lee Irwin III

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®