Skip to contentSkip to conversation

: libxc: set all VCPU's online by default in HVM info table

PATCH In review Gianni Tedesco 3 participants 3 messages Feb 11, 2011 – Apr 7, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 : libxc: set all VCPU's online by default in HVM info table

This sets a saner default for the cpu-online-map by setting all bits to
1. The default assumption ought to be that nr-vcpus == nr-vcpus-at-start. If that is not true, then the toolstack must modify the bitmap, but if it is true, the toolstack oughtn't need to do anything further.

tools/libxc/xc_hvm_build.c +1 -0
diff -r a0662e3bedea tools/libxc/xc_hvm_build.c
@@ -70,6 +70,7 @@ static void build_hvm_info(void *hvm_inf
     hvm_info->acpi_enabled = 1;
     hvm_info->apic_mode = 1;
     hvm_info->nr_vcpus = 1;
+    memset(hvm_info->vcpu_online, 0xff, sizeof(hvm_info->vcpu_online));
 
     /* Memory parameters. */
     hvm_info->low_mem_pgend = lowmem_end >> PAGE_SHIFT;
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Gianni Tedesco

This sets a saner default for the cpu-online-map by setting all bits to
1. The default assumption ought to be that nr-vcpus == nr-vcpus-at-start. If that is not true, then the toolstack must modify the bitmap, but if it is true, the toolstack oughtn't need to do anything further.

Quoted 19 lines

diff -r a0662e3bedea tools/libxc/xc_hvm_build.c

tools/libxc/xc_hvm_build.c +1 -0
@@ -70,6 +70,7 @@ static void build_hvm_info(void *hvm_inf
     hvm_info->acpi_enabled = 1;
     hvm_info->apic_mode = 1;
     hvm_info->nr_vcpus = 1;
+    memset(hvm_info->vcpu_online, 0xff, sizeof(hvm_info->vcpu_online));
 
     /* Memory parameters. */
     hvm_info->low_mem_pgend = lowmem_end >> PAGE_SHIFT;

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#2 lore raw

This patch seems to have been acked, but never actually applied. It's probably still worth applying at least to -unstable. I'd consider backporting it to 4.1 as well...

-George

Quoted 39 lines · Stefano Stabellini
Quoted 8 lines · Gianni Tedesco

This sets a saner default for the cpu-online-map by setting all bits to
1. The default assumption ought to be that nr-vcpus == nr-vcpus-at-start. If that is not true, then the toolstack must modify the bitmap, but if it is true, the toolstack oughtn't need to do anything further.

Quoted 14 lines

diff -r a0662e3bedea tools/libxc/xc_hvm_build.c

tools/libxc/xc_hvm_build.c      Fri Feb 11 14:39:47 2011 +0000 renamed from tools/libxc/xc_hvm_build.c      Fri Feb 11 14:28:14 2011 +0000 +1 -0
@@ -70,6 +70,7 @@ static void build_hvm_info(void *hvm_inf
      hvm_info->acpi_enabled = 1;
      hvm_info->apic_mode = 1;
      hvm_info->nr_vcpus = 1;
+    memset(hvm_info->vcpu_online, 0xff, sizeof(hvm_info->vcpu_online));
 
      /* Memory parameters. */
      hvm_info->low_mem_pgend = lowmem_end >> PAGE_SHIFT;
Quoted 5 lines

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel