diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2010-08-13 14:56:15 +0100 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2010-08-13 14:56:15 +0100 |
commit | 56b6043791a3bc00097836cc5f1d02bd56c472a5 (patch) | |
tree | c5dfd9463050f37411d80808df98e011b417fe2f /xen/arch/x86/sysctl.c | |
parent | fa2244104b42a8ab478b13eaba6bc86c87c0c167 (diff) | |
download | xen-56b6043791a3bc00097836cc5f1d02bd56c472a5.tar.gz xen-56b6043791a3bc00097836cc5f1d02bd56c472a5.tar.bz2 xen-56b6043791a3bc00097836cc5f1d02bd56c472a5.zip |
sysctl: Return physinfo.max_{cpu,node}_id as maximum *possible* IDs.
In particular, this fixes setting vcpu affinities via
libxl. Previously, the affinity mask would be narrowed to the maximum
currently-online CPU. So future hotplugged CPUs could not be
expressed.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Diffstat (limited to 'xen/arch/x86/sysctl.c')
-rw-r--r-- | xen/arch/x86/sysctl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xen/arch/x86/sysctl.c b/xen/arch/x86/sysctl.c index 5d22c5acb5..ac7b56a29b 100644 --- a/xen/arch/x86/sysctl.c +++ b/xen/arch/x86/sysctl.c @@ -62,8 +62,8 @@ long arch_do_sysctl( cpus_weight(per_cpu(cpu_core_map, 0)) / pi->threads_per_core; pi->nr_cpus = num_online_cpus(); pi->nr_nodes = num_online_nodes(); - pi->max_node_id = last_node(node_online_map); - pi->max_cpu_id = last_cpu(cpu_online_map); + pi->max_node_id = MAX_NUMNODES-1; + pi->max_cpu_id = NR_CPUS-1; pi->total_pages = total_pages; pi->free_pages = avail_domheap_pages(); pi->scrub_pages = 0; |