Module Name: src Committed By: macallan Date: Mon Dec 30 06:54:31 UTC 2019
Modified Files: src/sys/arch/sparc64/sparc64: cpu.c Log Message: add highly experimental NUMA support for US-IIIi machines To generate a diff of this commit: cvs rdiff -u -r1.136 -r1.137 src/sys/arch/sparc64/sparc64/cpu.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/sparc64/sparc64/cpu.c diff -u src/sys/arch/sparc64/sparc64/cpu.c:1.136 src/sys/arch/sparc64/sparc64/cpu.c:1.137 --- src/sys/arch/sparc64/sparc64/cpu.c:1.136 Tue Oct 1 18:00:08 2019 +++ src/sys/arch/sparc64/sparc64/cpu.c Mon Dec 30 06:54:31 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu.c,v 1.136 2019/10/01 18:00:08 chs Exp $ */ +/* $NetBSD: cpu.c,v 1.137 2019/12/30 06:54:31 macallan Exp $ */ /* * Copyright (c) 1996 @@ -52,7 +52,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.136 2019/10/01 18:00:08 chs Exp $"); +__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.137 2019/12/30 06:54:31 macallan Exp $"); #include "opt_multiprocessor.h" @@ -556,7 +556,15 @@ cpu_attach(device_t parent, device_t dev (u_int)GETVER_CPU_IMPL(), (u_int)GETVER_CPU_MASK()); } - +#ifdef NUMA + if (CPU_IS_USIIIi()) { + uint64_t start = ci->ci_cpuid; + start <<= 36; + ci->ci_numa_id = ci->ci_cpuid; + printf("NUMA bucket %d %016lx\n", ci->ci_cpuid, start); + uvm_page_numa_load(start, 0x1000000000, ci->ci_cpuid); + } +#endif if (ci->ci_system_clockrate[0] != 0) { aprint_normal_dev(dev, "system tick frequency %s MHz\n", clockfreq(ci->ci_system_clockrate[0]));