Skip to contentSkip to conversation

NUMA: broken per cpu pageset counters

PATCH New Magnus Damm 1 participant 1 message Oct 25, 2005

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 NUMA: broken per cpu pageset counters

The NUMA counters in struct per_cpu_pageset (linux/mmzone.h) are never cleared today. This works ok for CPU 0 on NUMA machines because boot_pageset[] is already zero, but for other CPU:s this results in uninitialized counters.

---

Tested on dual x86_64 hardware with 2.6.14-rc5-git5.

/proc/zoneinfo:
....

            numa_hit:       15064664480448666958
            numa_miss:      15061573751478353360
            numa_foreign:   15082960697523852788
            interleave_hit: 15083101074612482007
            local_node:     15084090651888212814
            other_node:     5860683432910092144

....

mm/page_alloc.c +2 -0
@@ -1750,6 +1750,8 @@ inline void setup_pageset(struct per_cpu
 {
 	struct per_cpu_pages *pcp;
 
+	memset(p, 0, sizeof(*p));
+
 	pcp = &p->pcp[0];		/* hot */
 	pcp->count = 0;
 	pcp->low = 2 * batch;

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>