]> xenbits.xensource.com Git - people/hx242/xen.git/commit
sched: add minimalistic idle scheduler for free cpus
authorJuergen Gross <jgross@suse.com>
Tue, 24 Sep 2019 15:11:02 +0000 (17:11 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 24 Sep 2019 15:11:02 +0000 (17:11 +0200)
commitf855dd962523b6cb47a92037bdd28b1485141abe
treeb102c811de4ec16e5fa122c738434fc194ee8224
parent73d1d61fa9de31575d7631a3390d70ba154d151b
sched: add minimalistic idle scheduler for free cpus

Instead of having a full blown scheduler running for the free cpus
add a very minimalistic scheduler for that purpose only ever scheduling
the related idle vcpu. This has the big advantage of not needing any
per-cpu, per-domain or per-scheduling unit data for free cpus and in
turn simplifying moving cpus to and from cpupools a lot.

Right now, CPUs that are not in any pool, still belong to Pool-0's
scheduler. This forces us to make, within the scheduler, extra effort
to avoid actually running vCPUs on those.

In the case of Credit1, this also cause issue to weights
(re)distribution, as the number of CPUs available to the scheduler is
wrong.

This is described in the changelog of commit e7191920261d ("xen:
credit2: never consider CPUs outside of our cpupool").

This new scheduler will just use a common lock for all free cpus.

As this new scheduler is not user selectable don't register it as an
official scheduler, but just include it in schedule.c.

Signed-off-by: Juergen Gross <jgross@suse.com>
Acked-by: Dario Faggioli <dfaggioli@suse.com>
xen/common/sched_credit.c
xen/common/sched_null.c
xen/common/schedule.c