xl: enable getting and setting soft affinity
authorDario Faggioli <dario.faggioli@citrix.com>
Tue, 29 Jul 2014 16:06:17 +0000 (18:06 +0200)
committerIan Campbell <ian.campbell@citrix.com>
Wed, 30 Jul 2014 11:44:44 +0000 (12:44 +0100)
commit7e474ba61c2fa6babf77466bbf4ce873733a9670
tree62a022ac948b70b1588adedde0311f7b41e2caf0
parent9ef51438e5410650c0525274dcfc7e1a503b6833
xl: enable getting and setting soft affinity

Getting happens via `xl vcpu-list', which now looks like this:

 # xl vcpu-list -s
 Name       ID VCPU CPU State Time(s) Affinity (Hard / Soft)
 Domain-0   0     0  11  -b-     5.4  8-15 / all
 Domain-0   0     1  11  -b-     1.0  8-15 / all
 Domain-0   0    14  13  -b-     1.4  8-15 / all
 Domain-0   0    15   8  -b-     1.6  8-15 / all
 vm-test    3     0   4  -b-     2.5  0-12 / 0-7
 vm-test    3     1   0  -b-     3.2  0-12 / 0-7

Setting happens by specifying two pCPU masks to the `xl vcpu-pin'
command, the first one will be hard affinity, the second soft
affinity. If only one mask is specified, it is only hard affinity
that is affected. To change only soft affinity, '-' can be used
as the hard affinity mask parameter, and it will be left alone.

xl manual page is updated accordingly.

Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
docs/man/xl.pod.1
tools/libxl/xl_cmdimpl.c
tools/libxl/xl_cmdtable.c