diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2010-04-23 08:38:35 +0100 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2010-04-23 08:38:35 +0100 |
commit | bb315e238429926ad570185fbdcad8ace008a791 (patch) | |
tree | 8dd84acbcfcb5aff39039c0c11491f88ce698dbc /xen/common/cpupool.c | |
parent | 261d19559d62f7b4b868275d54fa74315be9a42a (diff) | |
download | xen-bb315e238429926ad570185fbdcad8ace008a791.tar.gz xen-bb315e238429926ad570185fbdcad8ace008a791.tar.bz2 xen-bb315e238429926ad570185fbdcad8ace008a791.zip |
cpupools: optimise domain creation if pool movement is a no-op
Signed-off by: Juergen Gross <juergen.gross@ts.fujitsu.com>
Diffstat (limited to 'xen/common/cpupool.c')
-rw-r--r-- | xen/common/cpupool.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/xen/common/cpupool.c b/xen/common/cpupool.c index 7e32296061..6baedd0e14 100644 --- a/xen/common/cpupool.c +++ b/xen/common/cpupool.c @@ -520,6 +520,12 @@ addcpu_out: rcu_unlock_domain(d); break; } + if ( op->cpupool_id == d->cpupool->cpupool_id ) + { + ret = 0; + rcu_unlock_domain(d); + break; + } printk(XENLOG_DEBUG "cpupool move_domain(dom=%d)->pool=%d\n", d->domain_id, op->cpupool_id); ret = -ENOENT; |