Skip to contentSkip to conversation

_csched_cpu_pick(): don't return CPUs outside vCPU's affinity mask

PATCH New Jan Beulich 1 participant 1 message Mar 14, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 _csched_cpu_pick(): don't return CPUs outside vCPU's affinity mask

This fixes a fairly blatant bug I introduced in c/s 20377:cff23354d026
- I wonder how this went unnoticed for so long.

xen/common/sched_credit.c +1 -0
@@ -530,6 +531,7 @@ _csched_cpu_pick(const struct scheduler 
              || ( !sched_smt_power_savings
                   && (weight_cpu * migrate_factor < weight_nxt) ) )
         {
+            cpus_and(nxt_idlers, cpus, nxt_idlers);
             cpu = cycle_cpu(CSCHED_PCPU(nxt)->idle_bias, nxt_idlers);
             if ( commit )
                CSCHED_PCPU(nxt)->idle_bias = cpu;

This fixes a fairly blatant bug I introduced in c/s 20377:cff23354d026
- I wonder how this went unnoticed for so long.

xen/common/sched_credit.c +1 -0
@@ -530,6 +531,7 @@ _csched_cpu_pick(const struct scheduler 
              || ( !sched_smt_power_savings
                   && (weight_cpu * migrate_factor < weight_nxt) ) )
         {
+            cpus_and(nxt_idlers, cpus, nxt_idlers);
             cpu = cycle_cpu(CSCHED_PCPU(nxt)->idle_bias, nxt_idlers);
             if ( commit )
                CSCHED_PCPU(nxt)->idle_bias = cpu;

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel