This commit was manufactured by cvs2svn to create tag
[linux-2.6.git] / arch / x86_64 / mm / numa.c
index 12eef59..e6746a2 100644 (file)
@@ -10,8 +10,6 @@
 #include <linux/mmzone.h>
 #include <linux/ctype.h>
 #include <linux/module.h>
-#include <linux/nodemask.h>
-
 #include <asm/e820.h>
 #include <asm/proto.h>
 #include <asm/dma.h>
@@ -153,9 +151,9 @@ void __init numa_init_array(void)
        for (i = 0; i < MAXNODE; i++) {
                if (node_online(i))
                        continue;
-               rr = next_node(rr, node_online_map);
+               rr = find_next_bit(node_online_map, MAX_NUMNODES, rr);
                if (rr == MAX_NUMNODES)
-                       rr = first_node(node_online_map);
+                       rr = find_first_bit(node_online_map, MAX_NUMNODES);
                node_data[i] = node_data[rr];
                cpu_to_node[i] = rr;
                rr++; 
@@ -164,7 +162,6 @@ void __init numa_init_array(void)
        set_bit(0, &node_to_cpumask[cpu_to_node(0)]);
 }
 
-#ifdef CONFIG_NUMA_EMU
 int numa_fake __initdata = 0;
 
 /* Numa emulation */
@@ -209,16 +206,13 @@ static int numa_emulation(unsigned long start_pfn, unsigned long end_pfn)
        numa_init_array();
        return 0;
 }
-#endif
 
 void __init numa_initmem_init(unsigned long start_pfn, unsigned long end_pfn)
 { 
        int i;
 
-#ifdef CONFIG_NUMA_EMU
        if (numa_fake && !numa_emulation(start_pfn, end_pfn))
                return;
-#endif
 
 #ifdef CONFIG_K8_NUMA
        if (!numa_off && !k8_scan_nodes(start_pfn<<PAGE_SHIFT, end_pfn<<PAGE_SHIFT))
@@ -270,13 +264,11 @@ __init int numa_setup(char *opt)
 { 
        if (!strcmp(opt,"off"))
                numa_off = 1;
-#ifdef CONFIG_NUMA_EMU
        if(!strncmp(opt, "fake=", 5)) {
                numa_fake = simple_strtoul(opt+5,NULL,0); ;
                if (numa_fake >= MAX_NUMNODES)
                        numa_fake = MAX_NUMNODES;
        }
-#endif
        return 1;
 }