credit2: Avoid use of cpu_possible_map
authorKeir Fraser <keir.fraser@citrix.com>
Sat, 15 May 2010 08:16:47 +0000 (09:16 +0100)
committerKeir Fraser <keir.fraser@citrix.com>
Sat, 15 May 2010 08:16:47 +0000 (09:16 +0100)
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
xen/common/sched_credit2.c

index 14cea94e9da967a3e60801f3cebd91800d7515d8..3baf7147e5ae47ac0cf6d99cb17557d976ffe0b2 100644 (file)
@@ -1127,19 +1127,10 @@ csched_alloc_pdata(const struct scheduler *ops, int cpu)
 static void
 make_runq_map(struct csched_private *prv)
 {
-    int cpu, cpu_count=0;
-
     /* FIXME: Read pcpu layout and do this properly */
-    for_each_possible_cpu( cpu )
-    {
-        prv->runq_map[cpu] = 0;
-        cpu_count++;
-    }
     prv->runq_count = 1;
-
-    /* Move to the init code...? */
     prv->rqd[0].cpu_min = 0;
-    prv->rqd[0].cpu_max = cpu_count;
+    prv->rqd[0].cpu_max = NR_CPUS;
 }
 
 static int