]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - arch/mips/netlogic/xlp/wakeup.c
MIPS: Netlogic: Add cpu to node mapping for XLP9XX
[linux.git] / arch / mips / netlogic / xlp / wakeup.c
index a5d6647e5fe8030f627f885483036ffb2a6bea1d..bbd53f8e92dbfa4ea8c87d15b3f9cc76cf28d5a6 100644 (file)
@@ -165,7 +165,7 @@ static void xlp_enable_secondary_cores(const cpumask_t *wakeup_mask)
                        nodep->coremask = 1;
 
                pr_info("Node %d - SYS/FUSE coremask %x\n", n, syscoremask);
-               for (core = 0; core < NLM_CORES_PER_NODE; core++) {
+               for (core = 0; core < nlm_cores_per_node(); core++) {
                        /* we will be on node 0 core 0 */
                        if (n == 0 && core == 0)
                                continue;
@@ -175,7 +175,7 @@ static void xlp_enable_secondary_cores(const cpumask_t *wakeup_mask)
                                continue;
 
                        /* see if at least the first hw thread is enabled */
-                       cpu = (n * NLM_CORES_PER_NODE + core)
+                       cpu = (n * nlm_cores_per_node() + core)
                                                * NLM_THREADS_PER_CORE;
                        if (!cpumask_test_cpu(cpu, wakeup_mask))
                                continue;