[libvirt] [PATCH V3 0/2] Allow hot plugged host CPUs
by Viktor Mihajlovski
This is a rework of the original patch allowing to use all host
CPUs if the cpuset controller is not configured by libvirt.
The major enhancement is that we won't try to retrieve the online
host CPU map on platforms where this is not supported and just
fall back to the old behavior.
V3:
- Added new function (in seperate patch) to find out whether the host
CPU online map can be retrieved gracefully
V2:
- Avoid memory leak
Viktor Mihajlovski (2):
util: Allow to query the presence of host CPU bitmaps
qemu: Allow use of hot plugged host CPUs if no affinity set
src/libvirt_private.syms | 1 +
src/qemu/qemu_process.c | 33 ++++++++++++++++++++++++---------
src/util/virhostcpu.c | 10 ++++++++++
src/util/virhostcpu.h | 1 +
4 files changed, 36 insertions(+), 9 deletions(-)
--
1.9.1
8 years, 4 months
[libvirt] [PATCH] Avoid variable named 'stat'
by Daniel P. Berrange
Using a variable named 'stat' clashes with the system function
'stat()' causing compiler warnings on some platforms
cc1: warnings being treated as errors
../../src/qemu/qemu_monitor_text.c: In function 'parseMemoryStat':
../../src/qemu/qemu_monitor_text.c:604: error: declaration of 'stat' shadows a global declaration [-Wshadow]
/usr/include/sys/stat.h:455: error: shadowed declaration is here [-Wshadow]
Signed-off-by: Daniel P. Berrange <berrange(a)redhat.com>
---
Pushed as a build fix.
src/qemu/qemu_monitor_text.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/qemu/qemu_monitor_text.c b/src/qemu/qemu_monitor_text.c
index a2a5885..bc83218 100644
--- a/src/qemu/qemu_monitor_text.c
+++ b/src/qemu/qemu_monitor_text.c
@@ -601,7 +601,7 @@ int qemuMonitorTextGetVirtType(qemuMonitorPtr mon,
static int parseMemoryStat(char **text, unsigned int tag,
- const char *search, virDomainMemoryStatPtr stat)
+ const char *search, virDomainMemoryStatPtr mstat)
{
char *dummy;
unsigned long long value;
@@ -625,8 +625,8 @@ static int parseMemoryStat(char **text, unsigned int tag,
case VIR_DOMAIN_MEMORY_STAT_AVAILABLE:
value >>= 10;
}
- stat->tag = tag;
- stat->val = value;
+ mstat->tag = tag;
+ mstat->val = value;
return 1;
}
return 0;
--
2.9.3
8 years, 4 months
[libvirt] [PATCH] docs: Use href_base in absolute links
by Martin Kletzander
That way all links work even if you click them in a subdirectory.
Signed-off-by: Martin Kletzander <mkletzan(a)redhat.com>
---
docs/page.xsl | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/docs/page.xsl b/docs/page.xsl
index fcb51916ce25..1d662c670686 100644
--- a/docs/page.xsl
+++ b/docs/page.xsl
@@ -104,9 +104,9 @@
</div>
<div id="jumplinks">
<ul>
- <li><a href="downloads.html">Download</a></li>
- <li><a href="contribute.html">Contribute</a></li>
- <li><a href="docs.html">Learn</a></li>
+ <li><a href="{$href_base}downloads.html">Download</a></li>
+ <li><a href="{$href_base}contribute.html">Contribute</a></li>
+ <li><a href="{$href_base}docs.html">Learn</a></li>
</ul>
</div>
<div id="search">
@@ -122,8 +122,8 @@
<div id="contact">
<h3>Contact</h3>
<ul>
- <li><a href="contact.html#email">email</a></li>
- <li><a href="contact.html#irc">irc</a></li>
+ <li><a href="{$href_base}contact.html#email">email</a></li>
+ <li><a href="{$href_base}contact.html#irc">irc</a></li>
</ul>
</div>
<div id="community">
@@ -136,7 +136,7 @@
</ul>
</div>
<div id="conduct">
- Participants in the libvirt project agree to abide by <a href="governance.html#codeofconduct">the project code of conduct</a>
+ Participants in the libvirt project agree to abide by <a href="{$href_base}governance.html#codeofconduct">the project code of conduct</a>
</div>
<br class="clear"/>
</div>
--
2.11.0
8 years, 4 months
[libvirt] [PATCH jenkins-ci] Add libvirt-go to build
by Daniel P. Berrange
Signed-off-by: Daniel P. Berrange <berrange(a)redhat.com>
---
jobs/go.yaml | 71 ++++++++++++++++++++++++++++++++++++++++++++++++
projects/libvirt-go.yaml | 14 ++++++++++
2 files changed, 85 insertions(+)
create mode 100644 jobs/go.yaml
create mode 100644 projects/libvirt-go.yaml
diff --git a/jobs/go.yaml b/jobs/go.yaml
new file mode 100644
index 0000000..ce6f79b
--- /dev/null
+++ b/jobs/go.yaml
@@ -0,0 +1,71 @@
+
+- job-template:
+ id: go-build-job
+ name: '{name}-{branch}-build'
+ project-type: matrix
+ description: '{title} Build'
+ autogen_args: ''
+ workspace: '{name}-{branch}'
+ block-downstream: true
+ block-upstream: true
+ properties:
+ - build-discarder:
+ days-to-keep: 30
+ num-to-keep: 1000
+ scm:
+ - git:
+ url: git://n64.pufty.ci.centos.org/{name}.git
+ branches:
+ - origin/{branch}
+ clean:
+ after: true
+ skip-tag: true
+ wipe-workspace: false
+ triggers:
+ - reverse:
+ jobs: '{obj:parent_jobs}'
+ - pollscm:
+ cron: "H/20 * * * *"
+ axes:
+ - axis:
+ name: systems
+ type: slave
+ values: '{obj:machines}'
+ builders:
+ - shell: |
+ go build -v
+ publishers:
+ - email:
+ recipients: '{obj:spam}'
+ notify-every-unstable-build: true
+ send-to-individuals: false
+
+- job-template:
+ id: go-check-job
+ name: '{name}-{branch}-check'
+ project-type: matrix
+ description: '{title} Check'
+ check_env: ''
+ workspace: '{name}-{branch}'
+ block-downstream: true
+ block-upstream: true
+ properties:
+ - build-discarder:
+ days-to-keep: 30
+ num-to-keep: 1000
+ triggers:
+ - reverse:
+ jobs: '{obj:parent_jobs}'
+ axes:
+ - axis:
+ name: systems
+ type: slave
+ values: '{obj:machines}'
+ builders:
+ - shell: |
+ go test -tags api
+ publishers:
+ - email:
+ recipients: '{obj:spam}'
+ notify-every-unstable-build: true
+ send-to-individuals: false
diff --git a/projects/libvirt-go.yaml b/projects/libvirt-go.yaml
new file mode 100644
index 0000000..8ad7a2e
--- /dev/null
+++ b/projects/libvirt-go.yaml
@@ -0,0 +1,14 @@
+
+- project:
+ name: libvirt-go
+ machines:
+ - libvirt-centos-7
+ - libvirt-fedora-23
+ - libvirt-fedora-24
+ - libvirt-fedora-rawhide
+ title: Libvirt Go
+ jobs:
+ - go-build-job:
+ parent_jobs: 'libvirt-master-build'
+ - go-check-job:
+ parent_jobs: 'libvirt-go-master-build'
--
2.9.3
8 years, 4 months
[libvirt] [PATCH] Deal with gnutls 3.5.6 regression
by Daniel P. Berrange
I was not originally planning to do anything for the gnutls 3.5.6
regression:
https://www.redhat.com/archives/libvir-list/2016-November/msg00816.html
but there's still no immediate sign of the new 3.5.7 release,
so while I still don't want to workaround the bug in libvirt,
we can at least blacklist that version of gnutls in the test
suite, so 'make check' passes on affected systems while we're
waiting for 3.5.7 to arrive.
Daniel P. Berrange (1):
tests: blacklist gnutls 3.5.6 for wildcard tests
tests/virnettlssessiontest.c | 9 +++++++++
1 file changed, 9 insertions(+)
--
2.9.3
8 years, 4 months
[libvirt] [PATCH] qemu: Fix virQEMUCapsFindTarget on ppc64le
by Jiri Denemark
virQEMUCapsFindTarget is supposed to find an alternative QEMU binary if
qemu-system-$GUEST_ARCH doesn't exist. The alternative is using host
architecture when it is compatible with $GUEST_ARCH. But a special
treatment has to be applied for ppc64le since the QEMU binary is always
called qemu-system-ppc64.
Broken by me in v2.2.0-171-gf2e71550d.
https://bugzilla.redhat.com/show_bug.cgi?id=1403745
Signed-off-by: Jiri Denemark <jdenemar(a)redhat.com>
---
src/qemu/qemu_capabilities.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index 081afc566..f4ca84e98 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -482,13 +482,13 @@ static virArch
virQEMUCapsFindTarget(virArch hostarch,
virArch guestarch)
{
+ if (virQEMUCapsGuestIsNative(hostarch, guestarch))
+ guestarch = hostarch;
+
/* Both ppc64 and ppc64le guests can use the ppc64 target */
if (ARCH_IS_PPC64(guestarch))
guestarch = VIR_ARCH_PPC64;
- if (virQEMUCapsGuestIsNative(hostarch, guestarch))
- guestarch = hostarch;
-
return guestarch;
}
--
2.11.0
8 years, 4 months
[libvirt] [PATCH 0/2] Fix copy-pasta errors in config loading for aux daemons
by Peter Krempa
Apparently the option is not configured very often since nobody figured it out
until now.
Peter Krempa (2):
lock: Fix loading of config file for the lock daemon
log: Fix loading of conf file for log daemon
src/locking/lock_daemon_config.c | 2 +-
src/logging/log_daemon_config.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
--
2.11.0
8 years, 4 months
[libvirt] [PATCH for-2.9 00/17] target-i386: Implement query-cpu-model-expansion
by Eduardo Habkost
This series implements query-cpu-model-expansion on target-i386.
QAPI / interface changes
------------------------
When implementing this, I have noticed that the "host" CPU model
in i386 includes some migration-unsafe features that can't be
translated to any migration-safe representation: "pmu", and
"host-cache-info".
To be able to handle the migration-unsafe features, I have
extended the query-cpu-model-expansion definition to be clear
about what happens to those features when the CPU model is
expanded (in short: static expansion removes them, full expansion
keeps them).
I also added "static" and "migration-safe" fields to the return
value of query-cpu-model-expansion, so callers can know if the
the expanded representation is static and migration-safe.
Test code
---------
I have added a Python test script for the feature, that will try
multiple combinations of the expansion operation, and see if the
returned data keeps matches some constratins.
The test script works with the s390x query-cpu-model-expansion
command, except that: 1) I couldn't test it with KVM; 2) qtest.py
error handling when QEMU refuses to run is unreliable (so the
script needs runnability information to be availble in TCG mode,
too, to skip not-runnable CPU models and avoid problems).
Future versions of the test script could run a arch-specific
CPUID-dump guest binary, and validate data seen by the guest
directly. While we don't do that, the script validates all QOM
properties on the CPU objects looking for unexpected changes. At
least in the case of x86, the QOM properties will include lots of
the CPUID data seen by the guest, giving us decent coverage.
Patches from other series
-------------------------
This series includes patches from other series, just to help on
the implementation of the test code:
* "qmp: Report QOM type name on query-cpu-definitions", that
was already submitted for 2.9
* qemu.py, qtest.py, and tests/Makefile.include changes
---
Cc: Cornelia Huck <cornelia.huck(a)de.ibm.com>
Cc: Christian Borntraeger <borntraeger(a)de.ibm.com>
Cc: David Hildenbrand <david(a)redhat.com>
Cc: libvir-list(a)redhat.com
Cc: Jiri Denemark <jdenemar(a)redhat.com>
Cc: "Jason J. Herne" <jjherne(a)linux.vnet.ibm.com>
Cc: Markus Armbruster <armbru(a)redhat.com>
Cc: Richard Henderson <rth(a)twiddle.net>
Cc: Igor Mammedov <imammedo(a)redhat.com>
Cc: Eric Blake <eblake(a)redhat.com>
Eduardo Habkost (17):
qmp: Report QOM type name on query-cpu-definitions
qemu.py: Make logging optional
qtest.py: Support QTEST_LOG environment variable
qtest.py: make logging optional
qtest.py: Make 'binary' parameter optional
tests: Add rules to non-gtester qtest test cases
target-i386: Reorganize and document CPUID initialization steps
target-i386: Support "-cpu host" on TCG too
target-i386: Move "host" properties to base class
target-i386: Allow short strings to be used as vendor ID
target-i386: Remove AMD feature flag aliases from Opteron models
target-i386: Return migration-safe field on query-cpu-definitions
cpu: Support comma escaping when parsing -cpu
qapi: add static/migration-safe info to query-cpu-model-expansion
target-i386: Define static "base" CPU model
tests: query-cpu-model-test.py test code
target-i386: Implement query-cpu-model-expansion QMP command
qapi-schema.json | 30 ++-
scripts/qemu.py | 25 ++-
scripts/qtest.py | 15 +-
target-i386/cpu-qom.h | 8 +-
tests/Makefile.include | 40 +++-
tests/query-cpu-model-test.py | 421 ++++++++++++++++++++++++++++++++++++
tests/test-x86-cpuid-compat.c | 19 ++
monitor.c | 4 +-
qom/cpu.c | 32 ++-
target-arm/helper.c | 1 +
target-i386/cpu.c | 481 +++++++++++++++++++++++++++++++-----------
target-ppc/translate_init.c | 1 +
target-s390x/cpu_models.c | 5 +
13 files changed, 928 insertions(+), 154 deletions(-)
create mode 100755 tests/query-cpu-model-test.py
--
2.7.4
8 years, 4 months
[libvirt] [PATCH] docs: Update formatstorage to match code for pool path
by John Ferlan
Seems commit id '0257d06b' forgot to include formatstorage when updating
the docs to describe allowing zfs as a pool type and to furthermore note
that the pool's target path element will be generated rather than read.
Similarly commit id 'efab27afb' neglected to indicate that the target path
for a logical pool will now be generated by libvirt.
Signed-off-by: John Ferlan <jferlan(a)redhat.com>
---
Pushed as trivial
docs/formatstorage.html.in | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/docs/formatstorage.html.in b/docs/formatstorage.html.in
index f1be511..47c8b0c 100644
--- a/docs/formatstorage.html.in
+++ b/docs/formatstorage.html.in
@@ -380,8 +380,8 @@
<code>pool</code> element for some types of pools (pool
types <code>dir</code>, <code>fs</code>, <code>netfs</code>,
<code>logical</code>, <code>disk</code>, <code>iscsi</code>,
- <code>scsi</code>, <code>mpath</code>). This tag is used to
- describe the mapping of
+ <code>scsi</code>, <code>mpath</code>, <code>zfs</code>).
+ This tag is used to describe the mapping of
the storage pool into the host filesystem. It can contain the following
child elements:
</p>
@@ -411,6 +411,8 @@
guaranteed stable across reboots, since they are allocated on
demand. It is preferable to use a stable location such as one
of the <code>/dev/disk/by-{path|id|uuid|label}</code> locations.
+ For <code>logical</code> and <code>zfs</code> pool types, a
+ provided value is ignored and a default path generated.
For a Multipath pool (type <code>mpath</code>), the provided
value is ignored and the default value of "/dev/mapper" is used.
<span class="since">Since 0.4.1</span>
--
2.7.4
8 years, 4 months
[libvirt] [PATCH python] HACKING: fix grammar
by Cole Robinson
From: Prabodh Agarwal <prabodh1194(a)users.noreply.github.com>
---
Pushed as trivial. This was submitted on github, and since it's trivial
I just pushed it, but I pointed the user at the hacking guidelines for
future submissions
https://github.com/libvirt/libvirt-python/pull/1#issuecomment-266807394
HACKING | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/HACKING b/HACKING
index 7a6e150..6eeb9e6 100644
--- a/HACKING
+++ b/HACKING
@@ -3,7 +3,7 @@
Most of the libvirt python binding code is automatically generated
using the script generator.py, and the API description that the
-libvirt library installs the location shown by pkg-config, with
+libvirt library installs at the location shown by pkg-config, with
this command:
$ pkg-config --variable libvirt_api libvirt
--
2.9.3
8 years, 4 months