/* * This file is subject to the terms and conditions of the GNU General Public * License. See the file "COPYING" in the main directory of this archive * for more details. * * This file contains NUMA specific variables and functions which can * be split away from DISCONTIGMEM and are used on NUMA machines with * contiguous memory. * * 2002/08/07 Erich Focht <efocht@ess.nec.de> */ #include <linux/cpu.h> #include <linux/kernel.h> #include <linux/mm.h> #include <linux/node.h> #include <linux/init.h> #include <linux/bootmem.h> #include <linux/module.h> #include <asm/mmzone.h> #include <asm/numa.h> /* * The following structures are usually initialized by ACPI or * similar mechanisms and describe the NUMA characteristics of the machine. */ int num_node_memblks; struct node_memblk_s node_memblk[NR_NODE_MEMBLKS]; struct node_cpuid_s node_cpuid[NR_CPUS] = { [0 ... NR_CPUS-1] = { .phys_id = 0, .nid = NUMA_NO_NODE } }; /* * This is a matrix with "distances" between nodes, they should be * proportional to the memory access latency ratios. */ u8 numa_slit[MAX_NUMNODES * MAX_NUMNODES]; /* Identify which cnode a physical address resides on */
int paddr_to_nid(unsigned long paddr) { int i; for (i = 0; i < num_node_memblks; i++) if (paddr >= node_memblk[i].start_paddr && paddr < node_memblk[i].start_paddr + node_memblk[i].size) break; return (i < num_node_memblks) ? node_memblk[i].nid : (num_node_memblks ? -1 : 0); }Contributors
Person | Tokens | Prop | Commits | CommitProp |
Erich Focht | 68 | 89.47% | 1 | 33.33% |
Martin Hicks | 5 | 6.58% | 1 | 33.33% |
Andrew Morton | 3 | 3.95% | 1 | 33.33% |
Total | 76 | 100.00% | 3 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Bob Picco | 97 | 64.67% | 1 | 20.00% |
Russ Anderson | 28 | 18.67% | 1 | 20.00% |
Mel Gorman | 21 | 14.00% | 1 | 20.00% |
Kamezawa Hiroyuki | 4 | 2.67% | 2 | 40.00% |
Total | 150 | 100.00% | 5 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Yijing Wang | 15 | 100.00% | 1 | 100.00% |
Total | 15 | 100.00% | 1 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Keith Mannthey | 28 | 100.00% | 1 | 100.00% |
Total | 28 | 100.00% | 1 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Bob Picco | 111 | 29.84% | 1 | 7.14% |
Erich Focht | 108 | 29.03% | 1 | 7.14% |
Keith Mannthey | 42 | 11.29% | 1 | 7.14% |
Russ Anderson | 28 | 7.53% | 1 | 7.14% |
Robin Holt | 22 | 5.91% | 1 | 7.14% |
Mel Gorman | 21 | 5.65% | 1 | 7.14% |
Yijing Wang | 15 | 4.03% | 1 | 7.14% |
Andrew Morton | 7 | 1.88% | 2 | 14.29% |
Jesse Barnes | 6 | 1.61% | 1 | 7.14% |
Martin Hicks | 5 | 1.34% | 1 | 7.14% |
Kamezawa Hiroyuki | 4 | 1.08% | 2 | 14.29% |
Jes Sorensen | 3 | 0.81% | 1 | 7.14% |
Total | 372 | 100.00% | 14 | 100.00% |