Fix xm vcpu-pin for Domain-0
PATCH 1/1 Fix xm vcpu-pin for Domain-0
Hi,
A bogus error message is shown with the latest xen-unstable when using xm vcpu-pin command to Domain-0 and guest domains. I send a patch solving the issue.
# xm vcpu-pin Domain-0 0 0 Error: Cannot pin vcpu: 0 to cpu: [0] - list assignment index out of range Usage: xm vcpu-pin <Domain> <VCPU|all> <CPUs|all>
Set which CPUs a VCPU can use.
# xm vcpu-list Domain-0 Name ID VCPU CPU State Time(s) CPU Affinity Domain-0 0 0 0 r-- 52.1 0 Domain-0 0 1 1 -b- 27.0 any cpu
# xm create vm1 Using config file "/etc/xen/vm1". Started domain vm1 # xend stop # xend start # xm vcpu-pin vm1 0 0 Error: Cannot pin vcpu: 0 to cpu: [0] - list assignment index out of range Usage: xm vcpu-pin <Domain> <VCPU|all> <CPUs|all>
Set which CPUs a VCPU can use.
# xm vcpu-list vm1 Name ID VCPU CPU State Time(s) CPU Affinity vm1 1 0 0 -b- 31.2 0
Signed-off-by Masaki Kanno <[email protected]>
Best regards,
Kan
tools/python/xen/xend/XendDomainInfo.py +6 -0
@@ -1129,6 +1129,12 @@ class XendDomainInfo: else: self.info[arg] = val + # read CPU Affinity + self.info['cpus'] = [] + vcpus_info = self.getVCPUInfo() + for vcpu_info in sxp.children(vcpus_info, 'vcpu'): + self.info['cpus'].append(sxp.child_value(vcpu_info, 'cpumap')) + # For dom0, we ignore any stored value for the vcpus fields, and # read the current value from Xen instead. This allows boot-time # settings to take precedence over any entries in the store.
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 6 lines · Masaki Kanno
Hi,
A bogus error message is shown with the latest xen-unstable when using xm vcpu-pin command to Domain-0 and guest domains. I send a patch solving the issue.
....
Thanks, that fixes this issue for me (first read your mail after having pressed the send button ;-).
Regards,
Andre.
Signature · 9 lines
Andre Przywara AMD-Operating System Research Center (OSRC), Dresden, Germany Tel: +49 351 277-84917 ----to satisfy European Law for business letters: AMD Saxony Limited Liability Company & Co. KG, Wilschdorfer Landstr. 101, 01109 Dresden, Germany Register Court Dresden: HRA 4896, General Partner authorized to represent: AMD Saxony LLC (Wilmington, Delaware, US) General Manager of AMD Saxony LLC: Dr. Hans-R. Deppe, Thomas McCoy