[libvirt] [PATCH 0/2] conf: Avoid checking root element name in virDomainDefParseNode
by Jiri Denemark
The only caller for which this check makes sense is virDomainDefParse.
Thus the check should be moved there.
Jiri Denemark (2):
conf: Add cleanup label to virDomainDefParse
conf: Avoid checking root element name in virDomainDefParseNode
src/conf/domain_conf.c | 29 ++++++++++++++++-------------
1 file changed, 16 insertions(+), 13 deletions(-)
--
2.23.0
5 years, 2 months
[libvirt] [PATCH 0/6] qemu_conf: Use more VIR_AUTO*()
by Michal Privoznik
Michal Prívozník (6):
qemu_conf.c: Fix naming of *AddRemove* functions
qemu_conf: Drop a pair of needless 'cleanup' labels
qemu_conf: Use more of VIR_AUTOFREE()
qemu_conf: Use more of VIR_AUTOUNREF()
lxcParseConfigString: Don't return success if post parse callback
fails
lib: Define and use autofree for virConfPtr
src/bhyve/bhyve_conf.c | 10 +-
src/libvirt-admin.c | 3 +-
src/libvirt.c | 4 +-
src/libxl/libxl_conf.c | 22 +-
src/libxl/libxl_driver.c | 8 +-
src/libxl/xen_xl.c | 33 ++-
src/libxl/xen_xm.c | 19 +-
src/locking/lock_daemon_config.c | 7 +-
src/locking/lock_driver_lockd.c | 18 +-
src/locking/lock_driver_sanlock.c | 3 +-
src/logging/log_daemon_config.c | 7 +-
src/lxc/lxc_conf.c | 16 +-
src/lxc/lxc_native.c | 17 +-
src/qemu/qemu_conf.c | 360 ++++++++++++------------------
src/remote/remote_daemon_config.c | 14 +-
src/security/security_selinux.c | 4 +-
src/util/virconf.h | 2 +
src/vmx/vmx.c | 3 +-
tests/virconftest.c | 93 ++++----
tests/xlconfigtest.c | 8 +-
tests/xmconfigtest.c | 8 +-
tools/virt-login-shell-helper.c | 3 +-
22 files changed, 254 insertions(+), 408 deletions(-)
--
2.21.0
5 years, 2 months
[libvirt] [PATCH v3 0/5] PCI Multifunction hotplug/unplug, part 1
by Daniel Henrique Barboza
changes in v3:
- rebased after all PCI test changes went to master.
- a couple of patches were dropped due to redundancy with what
Michal already pushed upstream.
- patches 3 and 5 were already R-b by Michal in v2.
Hi,
In this new version I'm sending what was left to fix after
Michal pushed his "Drop KVM assignment" series, which ended
up having redundancy of fixes with the previous version.
This is the first part of the feature discussed at [1]. These
patches are mostly cleanup and fixes, thus it is beneficial
to have them upstream right away.
The whole feature can be checked out at [2]. All patches survives
unit testing. The feature was stress tested with hundreds
of consecutive hotplug/unplugs of a Broadcom BCM5719 multifunction
network card in a guest running in a Power 8 server. Hopefully
I'll find a suitable x86 env to stress test the feature there
too.
[1] https://www.redhat.com/archives/libvir-list/2019-June/msg00703.html
[2] https://github.com/danielhb/libvirt/tree/multifunction_latest
Daniel Henrique Barboza (2):
virpcimock.c: mock /dev/vfio
virpcimock.c: simplify getrealpath() usage
Shivaprasad G Bhat (3):
virpcimock: Mock the SRIOV Virtual functions
tests: Add test case for QEMU pci-hostdev hotplug
tests: Add a baseline test for multifunction pci device use case
src/util/virprocess.h | 2 +-
tests/Makefile.am | 7 +
tests/qemuhotplugtest.c | 40 ++-
.../qemuhotplug-hostdev-pci.xml | 6 +
.../qemuhotplug-base-live+hostdev-pci.xml | 58 +++++
...uhotplug-pseries-base-live+hostdev-pci.xml | 51 ++++
.../qemuhotplug-pseries-base-live.xml | 43 ++++
.../hostdev-pci-multifunction.args | 35 +++
.../hostdev-pci-multifunction.xml | 59 +++++
.../hostdev-vfio-multidomain.args | 2 +-
.../hostdev-vfio-multidomain.xml | 2 +-
tests/qemuxml2argvdata/hostdev-vfio.args | 2 +-
tests/qemuxml2argvdata/hostdev-vfio.xml | 2 +-
tests/qemuxml2argvdata/net-hostdev-fail.xml | 2 +-
tests/qemuxml2argvdata/net-hostdev-vfio.args | 2 +-
tests/qemuxml2argvdata/net-hostdev-vfio.xml | 2 +-
tests/qemuxml2argvtest.c | 3 +
.../hostdev-pci-multifunction.xml | 79 ++++++
tests/qemuxml2xmloutdata/hostdev-vfio.xml | 2 +-
tests/qemuxml2xmloutdata/net-hostdev-vfio.xml | 2 +-
tests/qemuxml2xmltest.c | 1 +
tests/virpcimock.c | 232 +++++++++++++++---
tests/virpcitestdata/0000-06-12.0.config | Bin 0 -> 256 bytes
tests/virpcitestdata/0000-06-12.1.config | Bin 0 -> 256 bytes
tests/virpcitestdata/0000-06-12.2.config | Bin 0 -> 256 bytes
tests/virprocessmock.c | 28 +++
26 files changed, 611 insertions(+), 51 deletions(-)
create mode 100644 tests/qemuhotplugtestdevices/qemuhotplug-hostdev-pci.xml
create mode 100644 tests/qemuhotplugtestdomains/qemuhotplug-base-live+hostdev-pci.xml
create mode 100644 tests/qemuhotplugtestdomains/qemuhotplug-pseries-base-live+hostdev-pci.xml
create mode 100644 tests/qemuhotplugtestdomains/qemuhotplug-pseries-base-live.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-pci-multifunction.args
create mode 100644 tests/qemuxml2argvdata/hostdev-pci-multifunction.xml
create mode 100644 tests/qemuxml2xmloutdata/hostdev-pci-multifunction.xml
create mode 100644 tests/virpcitestdata/0000-06-12.0.config
create mode 100644 tests/virpcitestdata/0000-06-12.1.config
create mode 100644 tests/virpcitestdata/0000-06-12.2.config
create mode 100644 tests/virprocessmock.c
--
2.21.0
5 years, 2 months
[libvirt] [PATCH] virhostdev: Don't unref @pcidevs twice
by Michal Privoznik
In f08e6883cb4 I've made @pcidevs in
virHostdevReAttachPCIDevices() to be automatically unrefed using
VIR_AUTOUNREF() but I forgot to remove the line that explicitly
unrefs the object at the end of the function.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
Pushed as trivial.
src/util/virhostdev.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index d710193b94..41fcab7222 100644
--- a/src/util/virhostdev.c
+++ b/src/util/virhostdev.c
@@ -1091,7 +1091,6 @@ virHostdevReAttachPCIDevices(virHostdevManagerPtr mgr,
virObjectUnlock(mgr->activePCIHostdevs);
virObjectUnlock(mgr->inactivePCIHostdevs);
- virObjectUnref(pcidevs);
}
int
--
2.21.0
5 years, 2 months
[libvirt] [PATCH 0/3] Fix memlock limit during hotplug of mdev devices
by Eric Farman
The routine qemuDomainGetMemLockLimitBytes() has a couple tests
to determine what the maximum limit of locked memory should be.
If I start a domain without any vfio stuff, /proc/$PID/limits says
the limit is 64KiB. If I start a guest with a vfio-ccw hostdev,
the limit is now $GUEST_MEMORY + 1GiB. It doesn't matter if I
have one hostdev or a thousand; it's always 1GiB more than the
configured amount of guest memory.
If I start a guest without any vfio devices, and hotplug that same
vfio-ccw hostdev, the limit remains at 64KiB and I start getting
I/O errors in the guest. This makes sense, since some of the I/O
chains are long enough to exceed that page limit, and the host
starts throwing errors.
There is already code that adjusts this limit during the hotplug
of vfio-pci devices, so patch 1 refactors that code so that it
can be re-used on the mdev hotplug path in patch 3.
Patch 2, meanwhile, adds some cleanup that I think is missing in
the vfio-pci path, based on my read of the mdev path.
$ grep locked /proc/83543/limits
Max locked memory 65536 65536 bytes
$ virsh attach-device guest scratch-ca8b.xml
Device attached successfully
$ grep locked /proc/83543/limits
Max locked memory 3221225472 3221225472 bytes
Eric Farman (3):
qemu: Refactor the max memlock routine
qemu: Reset the maximum locked memory on hotplug fail
qemu: Adjust max memlock on mdev hotplug
src/qemu/qemu_domain.c | 30 ++++++++++++++++++++++++++++++
src/qemu/qemu_domain.h | 2 ++
src/qemu/qemu_hotplug.c | 22 ++++++++++++----------
3 files changed, 44 insertions(+), 10 deletions(-)
--
2.17.1
5 years, 2 months
[libvirt] [dockerfiles PATCH v2] refresh: Update Dockerfiles due to new "locales" dependency
by Fabiano Fidêncio
Let's refresh the archived Dockerfiles as "locales" dependency has
to be added to all Debian, Ubuntu, and Fedora files.
Signed-off-by: Fabiano Fidêncio <fidencio(a)redhat.com>
---
buildenv-libosinfo-debian-10.zip | Bin 559 -> 629 bytes
buildenv-libosinfo-debian-sid.zip | Bin 559 -> 629 bytes
buildenv-libosinfo-fedora-29.zip | Bin 492 -> 502 bytes
buildenv-libosinfo-fedora-30.zip | Bin 555 -> 564 bytes
buildenv-libosinfo-fedora-rawhide.zip | Bin 512 -> 522 bytes
buildenv-libvirt-debian-10-cross-aarch64.zip | Bin 887 -> 956 bytes
buildenv-libvirt-debian-10-cross-armv6l.zip | Bin 880 -> 949 bytes
buildenv-libvirt-debian-10-cross-armv7l.zip | Bin 884 -> 954 bytes
buildenv-libvirt-debian-10-cross-i686.zip | Bin 883 -> 952 bytes
buildenv-libvirt-debian-10-cross-mips.zip | Bin 878 -> 947 bytes
buildenv-libvirt-debian-10-cross-mips64el.zip | Bin 892 -> 960 bytes
buildenv-libvirt-debian-10-cross-mipsel.zip | Bin 882 -> 952 bytes
buildenv-libvirt-debian-10-cross-ppc64le.zip | Bin 890 -> 961 bytes
buildenv-libvirt-debian-10-cross-s390x.zip | Bin 883 -> 951 bytes
buildenv-libvirt-debian-10.zip | Bin 773 -> 843 bytes
buildenv-libvirt-debian-9-cross-aarch64.zip | Bin 896 -> 964 bytes
buildenv-libvirt-debian-9-cross-armv6l.zip | Bin 887 -> 955 bytes
buildenv-libvirt-debian-9-cross-armv7l.zip | Bin 893 -> 961 bytes
buildenv-libvirt-debian-9-cross-mips.zip | Bin 886 -> 954 bytes
buildenv-libvirt-debian-9-cross-mips64el.zip | Bin 898 -> 966 bytes
buildenv-libvirt-debian-9-cross-mipsel.zip | Bin 889 -> 958 bytes
buildenv-libvirt-debian-9-cross-ppc64le.zip | Bin 898 -> 966 bytes
buildenv-libvirt-debian-9-cross-s390x.zip | Bin 890 -> 958 bytes
buildenv-libvirt-debian-9.zip | Bin 777 -> 846 bytes
buildenv-libvirt-debian-sid-cross-aarch64.zip | Bin 886 -> 956 bytes
buildenv-libvirt-debian-sid-cross-armv6l.zip | Bin 879 -> 948 bytes
buildenv-libvirt-debian-sid-cross-armv7l.zip | Bin 884 -> 954 bytes
buildenv-libvirt-debian-sid-cross-i686.zip | Bin 883 -> 952 bytes
buildenv-libvirt-debian-sid-cross-mips.zip | Bin 877 -> 947 bytes
buildenv-libvirt-debian-sid-cross-mips64el.zip | Bin 892 -> 960 bytes
buildenv-libvirt-debian-sid-cross-mipsel.zip | Bin 882 -> 951 bytes
buildenv-libvirt-debian-sid-cross-ppc64le.zip | Bin 890 -> 961 bytes
buildenv-libvirt-debian-sid-cross-s390x.zip | Bin 883 -> 951 bytes
buildenv-libvirt-debian-sid.zip | Bin 773 -> 843 bytes
buildenv-libvirt-fedora-29.zip | Bin 694 -> 706 bytes
buildenv-libvirt-fedora-30.zip | Bin 809 -> 821 bytes
buildenv-libvirt-fedora-rawhide.zip | Bin 714 -> 726 bytes
buildenv-libvirt-ubuntu-16.zip | Bin 784 -> 854 bytes
buildenv-libvirt-ubuntu-18.zip | Bin 783 -> 855 bytes
39 files changed, 0 insertions(+), 0 deletions(-)
diff --git a/buildenv-libosinfo-debian-10.zip b/buildenv-libosinfo-debian-10.zip
index 4a057eb..99f5121 100644
Binary files a/buildenv-libosinfo-debian-10.zip and b/buildenv-libosinfo-debian-10.zip differ
diff --git a/buildenv-libosinfo-debian-sid.zip b/buildenv-libosinfo-debian-sid.zip
index 86cf9dd..d006478 100644
Binary files a/buildenv-libosinfo-debian-sid.zip and b/buildenv-libosinfo-debian-sid.zip differ
diff --git a/buildenv-libosinfo-fedora-29.zip b/buildenv-libosinfo-fedora-29.zip
index 8fac1a5..7e49dbf 100644
Binary files a/buildenv-libosinfo-fedora-29.zip and b/buildenv-libosinfo-fedora-29.zip differ
diff --git a/buildenv-libosinfo-fedora-30.zip b/buildenv-libosinfo-fedora-30.zip
index 10f89e9..a028fa2 100644
Binary files a/buildenv-libosinfo-fedora-30.zip and b/buildenv-libosinfo-fedora-30.zip differ
diff --git a/buildenv-libosinfo-fedora-rawhide.zip b/buildenv-libosinfo-fedora-rawhide.zip
index 7cf81df..88d8b28 100644
Binary files a/buildenv-libosinfo-fedora-rawhide.zip and b/buildenv-libosinfo-fedora-rawhide.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-aarch64.zip b/buildenv-libvirt-debian-10-cross-aarch64.zip
index 8f2dbbc..99d6fd1 100644
Binary files a/buildenv-libvirt-debian-10-cross-aarch64.zip and b/buildenv-libvirt-debian-10-cross-aarch64.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-armv6l.zip b/buildenv-libvirt-debian-10-cross-armv6l.zip
index 774ff27..6f9f077 100644
Binary files a/buildenv-libvirt-debian-10-cross-armv6l.zip and b/buildenv-libvirt-debian-10-cross-armv6l.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-armv7l.zip b/buildenv-libvirt-debian-10-cross-armv7l.zip
index 893c929..bc69e02 100644
Binary files a/buildenv-libvirt-debian-10-cross-armv7l.zip and b/buildenv-libvirt-debian-10-cross-armv7l.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-i686.zip b/buildenv-libvirt-debian-10-cross-i686.zip
index 97e88e4..d496520 100644
Binary files a/buildenv-libvirt-debian-10-cross-i686.zip and b/buildenv-libvirt-debian-10-cross-i686.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-mips.zip b/buildenv-libvirt-debian-10-cross-mips.zip
index 332cb6c..6af1e1e 100644
Binary files a/buildenv-libvirt-debian-10-cross-mips.zip and b/buildenv-libvirt-debian-10-cross-mips.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-mips64el.zip b/buildenv-libvirt-debian-10-cross-mips64el.zip
index 7964dca..d381766 100644
Binary files a/buildenv-libvirt-debian-10-cross-mips64el.zip and b/buildenv-libvirt-debian-10-cross-mips64el.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-mipsel.zip b/buildenv-libvirt-debian-10-cross-mipsel.zip
index a4198d6..65087a7 100644
Binary files a/buildenv-libvirt-debian-10-cross-mipsel.zip and b/buildenv-libvirt-debian-10-cross-mipsel.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-ppc64le.zip b/buildenv-libvirt-debian-10-cross-ppc64le.zip
index 567f5b5..a892db1 100644
Binary files a/buildenv-libvirt-debian-10-cross-ppc64le.zip and b/buildenv-libvirt-debian-10-cross-ppc64le.zip differ
diff --git a/buildenv-libvirt-debian-10-cross-s390x.zip b/buildenv-libvirt-debian-10-cross-s390x.zip
index 42723f0..d4dfa9d 100644
Binary files a/buildenv-libvirt-debian-10-cross-s390x.zip and b/buildenv-libvirt-debian-10-cross-s390x.zip differ
diff --git a/buildenv-libvirt-debian-10.zip b/buildenv-libvirt-debian-10.zip
index 14634db..3353af9 100644
Binary files a/buildenv-libvirt-debian-10.zip and b/buildenv-libvirt-debian-10.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-aarch64.zip b/buildenv-libvirt-debian-9-cross-aarch64.zip
index 3fbf049..df304ad 100644
Binary files a/buildenv-libvirt-debian-9-cross-aarch64.zip and b/buildenv-libvirt-debian-9-cross-aarch64.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-armv6l.zip b/buildenv-libvirt-debian-9-cross-armv6l.zip
index 0e4a55d..efc035c 100644
Binary files a/buildenv-libvirt-debian-9-cross-armv6l.zip and b/buildenv-libvirt-debian-9-cross-armv6l.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-armv7l.zip b/buildenv-libvirt-debian-9-cross-armv7l.zip
index 6db735b..c7cc84a 100644
Binary files a/buildenv-libvirt-debian-9-cross-armv7l.zip and b/buildenv-libvirt-debian-9-cross-armv7l.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-mips.zip b/buildenv-libvirt-debian-9-cross-mips.zip
index 27b2a88..e984733 100644
Binary files a/buildenv-libvirt-debian-9-cross-mips.zip and b/buildenv-libvirt-debian-9-cross-mips.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-mips64el.zip b/buildenv-libvirt-debian-9-cross-mips64el.zip
index 04711c3..5a5d1c8 100644
Binary files a/buildenv-libvirt-debian-9-cross-mips64el.zip and b/buildenv-libvirt-debian-9-cross-mips64el.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-mipsel.zip b/buildenv-libvirt-debian-9-cross-mipsel.zip
index 0403a0b..9b4b450 100644
Binary files a/buildenv-libvirt-debian-9-cross-mipsel.zip and b/buildenv-libvirt-debian-9-cross-mipsel.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-ppc64le.zip b/buildenv-libvirt-debian-9-cross-ppc64le.zip
index 2edfed1..c983903 100644
Binary files a/buildenv-libvirt-debian-9-cross-ppc64le.zip and b/buildenv-libvirt-debian-9-cross-ppc64le.zip differ
diff --git a/buildenv-libvirt-debian-9-cross-s390x.zip b/buildenv-libvirt-debian-9-cross-s390x.zip
index aacac06..5217aa5 100644
Binary files a/buildenv-libvirt-debian-9-cross-s390x.zip and b/buildenv-libvirt-debian-9-cross-s390x.zip differ
diff --git a/buildenv-libvirt-debian-9.zip b/buildenv-libvirt-debian-9.zip
index 4ef6ccf..eb477f3 100644
Binary files a/buildenv-libvirt-debian-9.zip and b/buildenv-libvirt-debian-9.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-aarch64.zip b/buildenv-libvirt-debian-sid-cross-aarch64.zip
index 0583c1b..86dd0b6 100644
Binary files a/buildenv-libvirt-debian-sid-cross-aarch64.zip and b/buildenv-libvirt-debian-sid-cross-aarch64.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-armv6l.zip b/buildenv-libvirt-debian-sid-cross-armv6l.zip
index 0087dd3..9146520 100644
Binary files a/buildenv-libvirt-debian-sid-cross-armv6l.zip and b/buildenv-libvirt-debian-sid-cross-armv6l.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-armv7l.zip b/buildenv-libvirt-debian-sid-cross-armv7l.zip
index d296967..2d66e64 100644
Binary files a/buildenv-libvirt-debian-sid-cross-armv7l.zip and b/buildenv-libvirt-debian-sid-cross-armv7l.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-i686.zip b/buildenv-libvirt-debian-sid-cross-i686.zip
index 0f8bb16..40d8c1c 100644
Binary files a/buildenv-libvirt-debian-sid-cross-i686.zip and b/buildenv-libvirt-debian-sid-cross-i686.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-mips.zip b/buildenv-libvirt-debian-sid-cross-mips.zip
index 31912c4..bc858ca 100644
Binary files a/buildenv-libvirt-debian-sid-cross-mips.zip and b/buildenv-libvirt-debian-sid-cross-mips.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-mips64el.zip b/buildenv-libvirt-debian-sid-cross-mips64el.zip
index 3cbe12e..80e1b48 100644
Binary files a/buildenv-libvirt-debian-sid-cross-mips64el.zip and b/buildenv-libvirt-debian-sid-cross-mips64el.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-mipsel.zip b/buildenv-libvirt-debian-sid-cross-mipsel.zip
index 51c59db..3ba15c1 100644
Binary files a/buildenv-libvirt-debian-sid-cross-mipsel.zip and b/buildenv-libvirt-debian-sid-cross-mipsel.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-ppc64le.zip b/buildenv-libvirt-debian-sid-cross-ppc64le.zip
index 27dccb1..0542b8f 100644
Binary files a/buildenv-libvirt-debian-sid-cross-ppc64le.zip and b/buildenv-libvirt-debian-sid-cross-ppc64le.zip differ
diff --git a/buildenv-libvirt-debian-sid-cross-s390x.zip b/buildenv-libvirt-debian-sid-cross-s390x.zip
index 7504d28..a4f1528 100644
Binary files a/buildenv-libvirt-debian-sid-cross-s390x.zip and b/buildenv-libvirt-debian-sid-cross-s390x.zip differ
diff --git a/buildenv-libvirt-debian-sid.zip b/buildenv-libvirt-debian-sid.zip
index 874bb1b..7c576ae 100644
Binary files a/buildenv-libvirt-debian-sid.zip and b/buildenv-libvirt-debian-sid.zip differ
diff --git a/buildenv-libvirt-fedora-29.zip b/buildenv-libvirt-fedora-29.zip
index 43594d4..6fd188f 100644
Binary files a/buildenv-libvirt-fedora-29.zip and b/buildenv-libvirt-fedora-29.zip differ
diff --git a/buildenv-libvirt-fedora-30.zip b/buildenv-libvirt-fedora-30.zip
index 93773cb..9edc06c 100644
Binary files a/buildenv-libvirt-fedora-30.zip and b/buildenv-libvirt-fedora-30.zip differ
diff --git a/buildenv-libvirt-fedora-rawhide.zip b/buildenv-libvirt-fedora-rawhide.zip
index da6c064..f353c12 100644
Binary files a/buildenv-libvirt-fedora-rawhide.zip and b/buildenv-libvirt-fedora-rawhide.zip differ
diff --git a/buildenv-libvirt-ubuntu-16.zip b/buildenv-libvirt-ubuntu-16.zip
index 8cff046..5142f87 100644
Binary files a/buildenv-libvirt-ubuntu-16.zip and b/buildenv-libvirt-ubuntu-16.zip differ
diff --git a/buildenv-libvirt-ubuntu-18.zip b/buildenv-libvirt-ubuntu-18.zip
index 83546be..ca0c445 100644
Binary files a/buildenv-libvirt-ubuntu-18.zip and b/buildenv-libvirt-ubuntu-18.zip differ
--
2.21.0
5 years, 2 months
[libvirt] [jenkins-ci PATCH] lcitool: Generate the en_US.UTF-8 locale for deb containers
by Fabiano Fidêncio
osinfo-db tests require "en_US.UTF-8" locate to be set. Since commit
3b682c416b0d the locales are installed but we have to actually generate
it for the containers.
The reason we don't have to do that for the virtual machines is because
the preseed file used for installed them already forces it:
```
# Environment configuration
#
# Locale, keyboard and timezone. All these will be configured again
# later with Ansible, but they're required information so we must
# provide them
d-i debian-installer/locale string en_US.UTF-8
```
Signed-off-by: Fabiano Fidêncio <fidencio(a)redhat.com>
---
guests/lcitool | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/guests/lcitool b/guests/lcitool
index 5cf8efe..5b5b622 100755
--- a/guests/lcitool
+++ b/guests/lcitool
@@ -675,7 +675,9 @@ class Application:
{package_manager} dist-upgrade -y && \\
{package_manager} install --no-install-recommends -y {pkgs} && \\
{package_manager} autoremove -y && \\
- {package_manager} autoclean -y
+ {package_manager} autoclean -y && \\
+ sed -Ei 's,^# (en_US\.UTF-8 .*)$,\\1,' /etc/locale.gen && \\
+ dpkg-reconfigure locales
""").format(**varmap))
if args.cross_arch:
# Intentionally a separate RUN command from the above
--
2.21.0
5 years, 2 months
[libvirt] [PATCH] Revert "dbus: correctly build reply message"
by Michal Privoznik
This reverts commit 39dded7bb61444bb608fadd3f82f6fe93d08fd0e.
This commit broke virpolkittest on Ubuntu 18 which has an old
dbus (v1.12.2). Any other distro with the recent one works
(v1.12.16) which hints its a bug in dbus somewhere. Revert the
commit to stop tickling it.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/util/virdbus.c | 18 ++++++------------
src/util/virdbus.h | 6 ++----
tests/virfirewalltest.c | 9 +++------
tests/virpolkittest.c | 3 +--
4 files changed, 12 insertions(+), 24 deletions(-)
diff --git a/src/util/virdbus.c b/src/util/virdbus.c
index 64513eef14..b0ac8d7055 100644
--- a/src/util/virdbus.c
+++ b/src/util/virdbus.c
@@ -1456,7 +1456,6 @@ int virDBusCreateMethod(DBusMessage **call,
/**
* virDBusCreateReplyV:
- * @msg: the message to reply to
* @reply: pointer to be filled with a method reply message
* @types: type signature for following method arguments
* @args: method arguments
@@ -1469,14 +1468,13 @@ int virDBusCreateMethod(DBusMessage **call,
* as variadic args. See virDBusCreateMethodV for a
* description of this parameter.
*/
-int virDBusCreateReplyV(DBusMessage *msg,
- DBusMessage **reply,
+int virDBusCreateReplyV(DBusMessage **reply,
const char *types,
va_list args)
{
int ret = -1;
- if (!(*reply = dbus_message_new_method_return(msg))) {
+ if (!(*reply = dbus_message_new(DBUS_MESSAGE_TYPE_METHOD_RETURN))) {
virReportOOMError();
goto cleanup;
}
@@ -1495,7 +1493,6 @@ int virDBusCreateReplyV(DBusMessage *msg,
/**
* virDBusCreateReply:
- * @msg: the message to reply to
* @reply: pointer to be filled with a method reply message
* @types: type signature for following method arguments
* @...: method arguments
@@ -1503,15 +1500,14 @@ int virDBusCreateReplyV(DBusMessage *msg,
* See virDBusCreateReplyV for a description of the
* behaviour of this method.
*/
-int virDBusCreateReply(DBusMessage *msg,
- DBusMessage **reply,
+int virDBusCreateReply(DBusMessage **reply,
const char *types, ...)
{
va_list args;
int ret;
va_start(args, types);
- ret = virDBusCreateReplyV(msg, reply, types, args);
+ ret = virDBusCreateReplyV(reply, types, args);
va_end(args);
return ret;
@@ -1815,8 +1811,7 @@ int virDBusCreateMethodV(DBusMessage **call ATTRIBUTE_UNUSED,
return -1;
}
-int virDBusCreateReplyV(DBusMessage *msg ATTRIBUTE_UNUSED,
- DBusMessage **reply ATTRIBUTE_UNUSED,
+int virDBusCreateReplyV(DBusMessage **reply ATTRIBUTE_UNUSED,
const char *types ATTRIBUTE_UNUSED,
va_list args ATTRIBUTE_UNUSED)
{
@@ -1825,8 +1820,7 @@ int virDBusCreateReplyV(DBusMessage *msg ATTRIBUTE_UNUSED,
return -1;
}
-int virDBusCreateReply(DBusMessage *msg ATTRIBUTE_UNUSED,
- DBusMessage **reply ATTRIBUTE_UNUSED,
+int virDBusCreateReply(DBusMessage **reply ATTRIBUTE_UNUSED,
const char *types ATTRIBUTE_UNUSED, ...)
{
virReportError(VIR_ERR_INTERNAL_ERROR,
diff --git a/src/util/virdbus.h b/src/util/virdbus.h
index 0303e91045..083c074d59 100644
--- a/src/util/virdbus.h
+++ b/src/util/virdbus.h
@@ -52,11 +52,9 @@ int virDBusCreateMethodV(DBusMessage **call,
const char *member,
const char *types,
va_list args);
-int virDBusCreateReply(DBusMessage *msg,
- DBusMessage **reply,
+int virDBusCreateReply(DBusMessage **reply,
const char *types, ...);
-int virDBusCreateReplyV(DBusMessage *msg,
- DBusMessage **reply,
+int virDBusCreateReplyV(DBusMessage **reply,
const char *types,
va_list args);
diff --git a/tests/virfirewalltest.c b/tests/virfirewalltest.c
index e5eeb52175..78685a3bf4 100644
--- a/tests/virfirewalltest.c
+++ b/tests/virfirewalltest.c
@@ -150,8 +150,7 @@ VIR_MOCK_WRAP_RET_ARGS(dbus_connection_send_with_reply_and_block,
if (nargs == 1 &&
STREQ(type, "ipv4") &&
STREQ(args[0], "-L")) {
- if (virDBusCreateReply(message,
- &reply,
+ if (virDBusCreateReply(&reply,
"s", TEST_FILTER_TABLE_LIST) < 0)
goto error;
} else if (nargs == 3 &&
@@ -159,13 +158,11 @@ VIR_MOCK_WRAP_RET_ARGS(dbus_connection_send_with_reply_and_block,
STREQ(args[0], "-t") &&
STREQ(args[1], "nat") &&
STREQ(args[2], "-L")) {
- if (virDBusCreateReply(message,
- &reply,
+ if (virDBusCreateReply(&reply,
"s", TEST_NAT_TABLE_LIST) < 0)
goto error;
} else {
- if (virDBusCreateReply(message,
- &reply,
+ if (virDBusCreateReply(&reply,
"s", "success") < 0)
goto error;
}
diff --git a/tests/virpolkittest.c b/tests/virpolkittest.c
index 845ceb1736..ce1ff92bf2 100644
--- a/tests/virpolkittest.c
+++ b/tests/virpolkittest.c
@@ -123,8 +123,7 @@ VIR_MOCK_WRAP_RET_ARGS(dbus_connection_send_with_reply_and_block,
VIR_FREE(cancellationId);
virStringListFreeCount(details, detailslen);
- if (virDBusCreateReply(message,
- &reply,
+ if (virDBusCreateReply(&reply,
"(bba&{ss})",
is_authorized,
is_challenge,
--
2.21.0
5 years, 2 months
[libvirt] [PATCH v1 0/3] small code repetition purge on qemu_conf.c
by Daniel Henrique Barboza
Stumbled on this while changing qemu_conf.c for other
reasons. Moved code around here and there to avoid
repetition.
Final result is 23 less lines for the same functionality,
which is nothing to write home about but seems okay
to contribute.
Daniel Henrique Barboza (3):
qemu_conf.c: introduce qemuAddRemoveSharedHostdevInternal
qemu_conf.c: introduce qemuAddRemoveSharedDiskInternal
qemu_conf.c: introduce qemuAddRemoveSharedDeviceInternal
src/qemu/qemu_conf.c | 193 +++++++++++++++++++------------------------
1 file changed, 85 insertions(+), 108 deletions(-)
--
2.21.0
5 years, 2 months
[libvirt] [jenkins-ci PATCH v2] guests: Include "locales" by default
by Fabiano Fidêncio
osinfo-db tests require "en_US.UTF-8" locale to be set. Unfortunately,
our containers do not contain the needed locale file.
After a discussion on libosinfo mailing list[0], it's been agreed on
having the locale as part of our libvirt-jenkins-ci's base packages.
[0]: https://www.redhat.com/archives/libosinfo/2019-September/msg00011.html
Signed-off-by: Fabiano Fidêncio <fidencio(a)redhat.com>
---
guests/vars/mappings.yml | 6 ++++++
guests/vars/projects/base.yml | 1 +
2 files changed, 7 insertions(+)
diff --git a/guests/vars/mappings.yml b/guests/vars/mappings.yml
index c5a7824..bc6ea69 100644
--- a/guests/vars/mappings.yml
+++ b/guests/vars/mappings.yml
@@ -431,6 +431,12 @@ mappings:
rpm: libxslt-devel
cross-policy-deb: foreign
+ locales:
+ CentOS7: glibc-common
+ deb: locales
+ Fedora: glibc-langpack-en
+ FreeBSD:
+
lsof:
default: lsof
diff --git a/guests/vars/projects/base.yml b/guests/vars/projects/base.yml
index a7e572b..2a84029 100644
--- a/guests/vars/projects/base.yml
+++ b/guests/vars/projects/base.yml
@@ -16,6 +16,7 @@ packages:
- glibc
- libtool
- libtoolize
+ - locales
- lsof
- net-tools
- make
--
2.21.0
5 years, 2 months