]> xenbits.xensource.com Git - xen.git/commit
xen/sched: fix credit2 smt idle handling
authorJuergen Gross <jgross@suse.com>
Thu, 28 Mar 2019 15:46:22 +0000 (16:46 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 29 Mar 2019 18:28:21 +0000 (18:28 +0000)
commit753ba43d6d16e688f688e01e1c77463ea2c6ec9f
tree18067e366b2a2f4f00790dd62450cf67f9d52b26
parente88afede8cbc18032bcab49b3a25b472d5516cf5
xen/sched: fix credit2 smt idle handling

Credit2's smt_idle_mask_set() and smt_idle_mask_clear() are used to
identify idle cores where vcpus can be moved to. A core is thought to
be idle when all siblings are known to have the idle vcpu running on
them.

Unfortunately the information of a vcpu running on a cpu is per
runqueue. So in case not all siblings are in the same runqueue a core
will never be regarded to be idle, as the sibling not in the runqueue
is never known to run the idle vcpu.

Use a credit2 specific cpumask of siblings with only those cpus
being marked which are in the same runqueue as the cpu in question.

Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Dario Faggioli <dfaggioli@suse.com>
xen/common/sched_credit2.c