[PATCH libvirt v2 0/5] Fix zPCI address auto-generation on s390
by Shalini Chellathurai Saroja
The zPCI address validation or autogeneration does not work as
expected in the following scenarios
1. uid = 0 and fid = 0
2. uid = 0 and fid > 0
3. uid = 0 and fid not specified
4. uid not specified and fid > 0
5. 2 zPCI devices with uid > 0 and fid not specified.
This is because of the following reasons
1. If uid = 0 or fid = 0 the code assumes that user has not specified
the corresponding address
2. If either uid or fid is provided, the code assumes that both uid
and fid addresses are specified by the user.
This patch fixes these issues.
---
v2:
- Call same function to reserve zPCI address when zPCI address is
fully/partially/not specified by the user.
- Redefine structure of zPCI address.
- Add tests to verify the auto-generated xml(qemuxml2xmltest.c).
- Separate/merge patches.
- Minor changes based on review feedback.
v1:
https://www.redhat.com/archives/libvir-list/2020-April/msg00479.html
Shalini Chellathurai Saroja (5):
conf: use g_autofree to ensure automatic cleanup
conf: fix zPCI address auto-generation on s390
qemu: move ZPCI uid validation into device validation
tests: qemu: add more tests for ZPCI on S390
tests: add test with PCI and CCW device
src/conf/device_conf.c | 45 +++++------
src/conf/domain_addr.c | 77 ++++++-------------
src/conf/domain_conf.c | 10 ++-
src/libvirt_private.syms | 4 +-
src/qemu/qemu_command.c | 6 +-
src/qemu/qemu_hotplug.c | 2 +-
src/qemu/qemu_validate.c | 18 ++++-
src/util/virpci.c | 23 ++----
src/util/virpci.h | 15 +++-
.../hostdev-vfio-zpci-autogenerate-fids.args | 31 ++++++++
.../hostdev-vfio-zpci-autogenerate-fids.xml | 29 +++++++
.../hostdev-vfio-zpci-autogenerate-uids.args | 31 ++++++++
.../hostdev-vfio-zpci-autogenerate-uids.xml | 29 +++++++
.../hostdev-vfio-zpci-ccw-memballoon.args | 28 +++++++
.../hostdev-vfio-zpci-ccw-memballoon.xml | 17 ++++
.../hostdev-vfio-zpci-duplicate.xml | 30 ++++++++
...ostdev-vfio-zpci-invalid-uid-valid-fid.xml | 21 +++++
.../hostdev-vfio-zpci-set-zero.xml | 21 +++++
.../hostdev-vfio-zpci-uid-set-zero.xml | 20 +++++
tests/qemuxml2argvtest.c | 25 ++++++
.../hostdev-vfio-zpci-autogenerate-fids.xml | 43 +++++++++++
.../hostdev-vfio-zpci-autogenerate-uids.xml | 43 +++++++++++
.../hostdev-vfio-zpci-ccw-memballoon.xml | 32 ++++++++
tests/qemuxml2xmltest.c | 10 +++
24 files changed, 498 insertions(+), 112 deletions(-)
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-autogenerate-fids.args
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-autogenerate-fids.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-autogenerate-uids.args
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-autogenerate-uids.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-ccw-memballoon.args
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-ccw-memballoon.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-duplicate.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-invalid-uid-valid-fid.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-set-zero.xml
create mode 100644 tests/qemuxml2argvdata/hostdev-vfio-zpci-uid-set-zero.xml
create mode 100644 tests/qemuxml2xmloutdata/hostdev-vfio-zpci-autogenerate-fids.xml
create mode 100644 tests/qemuxml2xmloutdata/hostdev-vfio-zpci-autogenerate-uids.xml
create mode 100644 tests/qemuxml2xmloutdata/hostdev-vfio-zpci-ccw-memballoon.xml
--
2.25.4
4 years, 5 months
[libvirt PATCH v2] ci: Use openSUSE image for code style checking
by Jonathon Jongsma
CentOS does not have the cppi package, so some code style checks are
skipped. Switch to a openSUSE image to do the code style checks.
Signed-off-by: Jonathon Jongsma <jjongsma(a)redhat.com>
---
.gitlab-ci.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index bfb66a652d..5fbc82b3dc 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -496,7 +496,7 @@ website:
codestyle:
stage: builds
- image: $CI_REGISTRY_IMAGE/ci-centos-8:latest
+ image: $CI_REGISTRY_IMAGE/ci-opensuse-151:latest
before_script:
- *script_variables
script:
--
2.21.3
4 years, 5 months
[libvirt PATCH v3 0/2] Refuse PCI Address for ramfb device definition
by Jonathon Jongsma
Changes in this version:
- Add the test case input file
- modify the test itself to properly fail when an input file is missing.
Jonathon Jongsma (2):
qemu: ramfb video device doesn't support PCI address
tests: ensure failure if input file doesn't exist
src/qemu/qemu_validate.c | 8 +++++
...video-ramfb-display-device-pci-address.xml | 30 +++++++++++++++++++
tests/qemuxml2argvtest.c | 7 +++++
3 files changed, 45 insertions(+)
create mode 100644 tests/qemuxml2argvdata/video-ramfb-display-device-pci-address.xml
--
2.21.3
4 years, 5 months
[PATCH libvirt-dbus v3 0/3] Introduce GitLab CI and merge requests
by Daniel P. Berrangé
This introduces CI build coverage and then documents the switch to
use merge requests.
Daniel P. Berrangé (3):
src: fix double free of virDomain object
gitlab: introduce CI jobs testing git master & distro libvirt
gitlab: add CONTRIBUTING.rst file to indicate use of merge requests
.gitlab-ci.yml | 218 ++++++++++++++++++
.gitpublish | 4 -
CONTRIBUTING.rst | 28 +++
ci/containers/README.rst | 14 ++
ci/containers/libvirt-centos-7.Dockerfile | 90 ++++++++
ci/containers/libvirt-centos-8.Dockerfile | 68 ++++++
.../libvirt-centos-stream.Dockerfile | 69 ++++++
ci/containers/libvirt-debian-10.Dockerfile | 61 +++++
ci/containers/libvirt-debian-9.Dockerfile | 64 +++++
ci/containers/libvirt-debian-sid.Dockerfile | 61 +++++
ci/containers/libvirt-fedora-31.Dockerfile | 58 +++++
ci/containers/libvirt-fedora-32.Dockerfile | 58 +++++
.../libvirt-fedora-rawhide.Dockerfile | 59 +++++
ci/containers/libvirt-opensuse-151.Dockerfile | 60 +++++
ci/containers/libvirt-ubuntu-1804.Dockerfile | 64 +++++
ci/containers/libvirt-ubuntu-2004.Dockerfile | 61 +++++
ci/containers/refresh | 37 +++
src/domainsnapshot.c | 4 +-
18 files changed, 1072 insertions(+), 6 deletions(-)
delete mode 100644 .gitpublish
create mode 100644 CONTRIBUTING.rst
create mode 100644 ci/containers/README.rst
create mode 100644 ci/containers/libvirt-centos-7.Dockerfile
create mode 100644 ci/containers/libvirt-centos-8.Dockerfile
create mode 100644 ci/containers/libvirt-centos-stream.Dockerfile
create mode 100644 ci/containers/libvirt-debian-10.Dockerfile
create mode 100644 ci/containers/libvirt-debian-9.Dockerfile
create mode 100644 ci/containers/libvirt-debian-sid.Dockerfile
create mode 100644 ci/containers/libvirt-fedora-31.Dockerfile
create mode 100644 ci/containers/libvirt-fedora-32.Dockerfile
create mode 100644 ci/containers/libvirt-fedora-rawhide.Dockerfile
create mode 100644 ci/containers/libvirt-opensuse-151.Dockerfile
create mode 100644 ci/containers/libvirt-ubuntu-1804.Dockerfile
create mode 100644 ci/containers/libvirt-ubuntu-2004.Dockerfile
create mode 100755 ci/containers/refresh
--
2.26.2
4 years, 5 months
[libvirt PATCH v2] qemu: ramfb video device doesn't support PCI address
by Jonathon Jongsma
Although a ramfb video device is not a PCI device, we don't currently
report an error for ramfb device definitions containing a PCI address.
However, a guest configured with such a device will fail to start:
# virsh start test1
error: Failed to start domain test1
error: internal error: qemu unexpectedly closed the monitor: 2020-06-16T05:23:02.759221Z qemu-kvm: -device ramfb,id=video0,bus=pcie.0,addr=0x1: Device 'ramfb' can't go on PCIE bus
A better approach is to reject any device definitions that contain PCI
addresses. While this is a change in behavior, any existing
configurations were non-functional.
https://bugzilla.redhat.com/show_bug.cgi?id=1847259
Signed-off-by: Jonathon Jongsma <jjongsma(a)redhat.com>
---
changes in v2:
- move validation to qemu-specific validation function as suggested by Laine
src/qemu/qemu_validate.c | 8 ++++++++
tests/qemuxml2argvtest.c | 1 +
2 files changed, 9 insertions(+)
diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c
index 5082a29dc7..b13c03759e 100644
--- a/src/qemu/qemu_validate.c
+++ b/src/qemu/qemu_validate.c
@@ -1925,6 +1925,14 @@ qemuValidateDomainDeviceDefVideo(const virDomainVideoDef *video,
if (qemuValidateDomainVirtioOptions(video->virtio, qemuCaps) < 0)
return -1;
+ if (video->type == VIR_DOMAIN_VIDEO_TYPE_RAMFB &&
+ video->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) {
+ virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+ _("'address' is not supported for 'ramfb' video devices"));
+ return -1;
+ }
+
+
return 0;
}
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 1195f9c982..f2522fa530 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -2276,6 +2276,7 @@ mymain(void)
QEMU_CAPS_VIRTIO_GPU_MAX_OUTPUTS);
DO_TEST_CAPS_LATEST("video-bochs-display-device");
DO_TEST_CAPS_LATEST("video-ramfb-display-device");
+ DO_TEST_CAPS_LATEST_PARSE_ERROR("video-ramfb-display-device-pci-address");
DO_TEST("video-none-device",
QEMU_CAPS_VNC);
DO_TEST_PARSE_ERROR("video-invalid-multiple-devices", NONE);
--
2.21.3
4 years, 5 months
[PATCH] qemuxml2xmltest: Set dummy non-hypervisor drivers
by Michal Privoznik
When parsing domain XML post parse callbacks are run and one of
them might try and call API from a non-hypervisor driver (e.g.
just like qemuDomainDeviceNetDefPostParse() is doing - it calls a
network API). To avoid this in the test suite, set dummy drivers,
which renders all non-hypervisor APIs return error.
This mimics what qemuxml2argvtest does.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
tests/qemuxml2xmltest.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
index 5a124853b4..11ff17d83c 100644
--- a/tests/qemuxml2xmltest.c
+++ b/tests/qemuxml2xmltest.c
@@ -135,6 +135,7 @@ mymain(void)
char *fakerootdir;
virQEMUDriverConfigPtr cfg = NULL;
virHashTablePtr capslatest = NULL;
+ g_autoptr(virConnect) conn = NULL;
capslatest = testQemuGetLatestCaps();
if (!capslatest)
@@ -164,6 +165,16 @@ mymain(void)
cfg = virQEMUDriverGetConfig(&driver);
driver.privileged = true;
+ if (!(conn = virGetConnect()))
+ goto cleanup;
+
+ virSetConnectInterface(conn);
+ virSetConnectNetwork(conn);
+ virSetConnectNWFilter(conn);
+ virSetConnectNodeDev(conn);
+ virSetConnectSecret(conn);
+ virSetConnectStorage(conn);
+
# define DO_TEST_INTERNAL(_name, suffix, when, ...) \
do { \
static struct testQemuInfo info = { \
@@ -1471,6 +1482,7 @@ mymain(void)
DO_TEST_CAPS_LATEST("virtio-9p-multidevs");
DO_TEST("downscript", NONE);
+ cleanup:
if (getenv("LIBVIRT_SKIP_CLEANUP") == NULL)
virFileDeleteTree(fakerootdir);
--
2.26.2
4 years, 5 months
[PATCH libvirt-dbus v2 0/3] Introduce GitLab CI and merge requests
by Daniel P. Berrangé
This introduces CI build coverage and then documents the switch to
use merge requests.
Daniel P. Berrangé (3):
src: fix double free of virDomain object
gitlab: introduce CI jobs testing git master & distro libvirt
gitlab: add CONTRIBUTING.rst file to indicate use of merge requests
.gitlab-ci.yml | 218 ++++++++++++++++++
.gitpublish | 4 -
CONTRIBUTING.rst | 28 +++
ci/containers/README.rst | 14 ++
ci/containers/libvirt-centos-7.Dockerfile | 90 ++++++++
ci/containers/libvirt-centos-8.Dockerfile | 68 ++++++
.../libvirt-centos-stream.Dockerfile | 69 ++++++
ci/containers/libvirt-debian-10.Dockerfile | 61 +++++
ci/containers/libvirt-debian-9.Dockerfile | 64 +++++
ci/containers/libvirt-debian-sid.Dockerfile | 61 +++++
ci/containers/libvirt-fedora-31.Dockerfile | 58 +++++
ci/containers/libvirt-fedora-32.Dockerfile | 58 +++++
.../libvirt-fedora-rawhide.Dockerfile | 59 +++++
ci/containers/libvirt-opensuse-151.Dockerfile | 60 +++++
ci/containers/libvirt-ubuntu-1804.Dockerfile | 64 +++++
ci/containers/libvirt-ubuntu-2004.Dockerfile | 61 +++++
ci/containers/refresh | 32 +++
src/domainsnapshot.c | 4 +-
18 files changed, 1067 insertions(+), 6 deletions(-)
delete mode 100644 .gitpublish
create mode 100644 CONTRIBUTING.rst
create mode 100644 ci/containers/README.rst
create mode 100644 ci/containers/libvirt-centos-7.Dockerfile
create mode 100644 ci/containers/libvirt-centos-8.Dockerfile
create mode 100644 ci/containers/libvirt-centos-stream.Dockerfile
create mode 100644 ci/containers/libvirt-debian-10.Dockerfile
create mode 100644 ci/containers/libvirt-debian-9.Dockerfile
create mode 100644 ci/containers/libvirt-debian-sid.Dockerfile
create mode 100644 ci/containers/libvirt-fedora-31.Dockerfile
create mode 100644 ci/containers/libvirt-fedora-32.Dockerfile
create mode 100644 ci/containers/libvirt-fedora-rawhide.Dockerfile
create mode 100644 ci/containers/libvirt-opensuse-151.Dockerfile
create mode 100644 ci/containers/libvirt-ubuntu-1804.Dockerfile
create mode 100644 ci/containers/libvirt-ubuntu-2004.Dockerfile
create mode 100755 ci/containers/refresh
--
2.26.2
4 years, 5 months
[libvirt PATCH] ci: Refresh Dockerfiles
by Andrea Bolognani
All targets get pip3, which is now part of the base system, and
the number of native packages included in the MinGW containers is
significantly reduced.
The corresponding libvirt-ci commit is 4ff697ba0b5d.
Signed-off-by: Andrea Bolognani <abologna(a)redhat.com>
---
Pushed under the Dockerfile refresh rule.
ci/containers/libvirt-centos-8.Dockerfile | 1 +
.../libvirt-centos-stream.Dockerfile | 1 +
...libvirt-debian-10-cross-aarch64.Dockerfile | 1 +
.../libvirt-debian-10-cross-armv6l.Dockerfile | 1 +
.../libvirt-debian-10-cross-armv7l.Dockerfile | 1 +
.../libvirt-debian-10-cross-i686.Dockerfile | 1 +
.../libvirt-debian-10-cross-mips.Dockerfile | 1 +
...ibvirt-debian-10-cross-mips64el.Dockerfile | 1 +
.../libvirt-debian-10-cross-mipsel.Dockerfile | 1 +
...libvirt-debian-10-cross-ppc64le.Dockerfile | 1 +
.../libvirt-debian-10-cross-s390x.Dockerfile | 1 +
ci/containers/libvirt-debian-10.Dockerfile | 1 +
...ibvirt-debian-sid-cross-aarch64.Dockerfile | 1 +
...libvirt-debian-sid-cross-armv6l.Dockerfile | 1 +
...libvirt-debian-sid-cross-armv7l.Dockerfile | 1 +
.../libvirt-debian-sid-cross-i686.Dockerfile | 1 +
...bvirt-debian-sid-cross-mips64el.Dockerfile | 1 +
...libvirt-debian-sid-cross-mipsel.Dockerfile | 1 +
...ibvirt-debian-sid-cross-ppc64le.Dockerfile | 1 +
.../libvirt-debian-sid-cross-s390x.Dockerfile | 1 +
ci/containers/libvirt-debian-sid.Dockerfile | 1 +
ci/containers/libvirt-fedora-31.Dockerfile | 1 +
ci/containers/libvirt-fedora-32.Dockerfile | 1 +
...rt-fedora-rawhide-cross-mingw32.Dockerfile | 42 +------------------
...rt-fedora-rawhide-cross-mingw64.Dockerfile | 42 +------------------
.../libvirt-fedora-rawhide.Dockerfile | 1 +
ci/containers/libvirt-ubuntu-2004.Dockerfile | 1 +
27 files changed, 29 insertions(+), 80 deletions(-)
diff --git a/ci/containers/libvirt-centos-8.Dockerfile b/ci/containers/libvirt-centos-8.Dockerfile
index b6510834de..f376126d93 100644
--- a/ci/containers/libvirt-centos-8.Dockerfile
+++ b/ci/containers/libvirt-centos-8.Dockerfile
@@ -76,6 +76,7 @@ RUN dnf install 'dnf-command(config-manager)' -y && \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
diff --git a/ci/containers/libvirt-centos-stream.Dockerfile b/ci/containers/libvirt-centos-stream.Dockerfile
index f65580b67d..bc75c95193 100644
--- a/ci/containers/libvirt-centos-stream.Dockerfile
+++ b/ci/containers/libvirt-centos-stream.Dockerfile
@@ -77,6 +77,7 @@ RUN dnf install -y centos-release-stream && \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
diff --git a/ci/containers/libvirt-debian-10-cross-aarch64.Dockerfile b/ci/containers/libvirt-debian-10-cross-aarch64.Dockerfile
index 3620bbdf7f..a03a7fd26a 100644
--- a/ci/containers/libvirt-debian-10-cross-aarch64.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-aarch64.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-armv6l.Dockerfile b/ci/containers/libvirt-debian-10-cross-armv6l.Dockerfile
index 5d390d0160..4f673cb3e2 100644
--- a/ci/containers/libvirt-debian-10-cross-armv6l.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-armv6l.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-armv7l.Dockerfile b/ci/containers/libvirt-debian-10-cross-armv7l.Dockerfile
index 2fdbe99bff..fa5fae4399 100644
--- a/ci/containers/libvirt-debian-10-cross-armv7l.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-armv7l.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-i686.Dockerfile b/ci/containers/libvirt-debian-10-cross-i686.Dockerfile
index 6517a4cb2e..a3bc96ac7a 100644
--- a/ci/containers/libvirt-debian-10-cross-i686.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-i686.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-mips.Dockerfile b/ci/containers/libvirt-debian-10-cross-mips.Dockerfile
index 48a45dbb7a..14844307c0 100644
--- a/ci/containers/libvirt-debian-10-cross-mips.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-mips.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-mips64el.Dockerfile b/ci/containers/libvirt-debian-10-cross-mips64el.Dockerfile
index 1d997185e4..6f27e462b9 100644
--- a/ci/containers/libvirt-debian-10-cross-mips64el.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-mips64el.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-mipsel.Dockerfile b/ci/containers/libvirt-debian-10-cross-mipsel.Dockerfile
index 332f2b13ed..4da9d1cb6e 100644
--- a/ci/containers/libvirt-debian-10-cross-mipsel.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-mipsel.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-ppc64le.Dockerfile b/ci/containers/libvirt-debian-10-cross-ppc64le.Dockerfile
index ec116175fc..841706bab8 100644
--- a/ci/containers/libvirt-debian-10-cross-ppc64le.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-ppc64le.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10-cross-s390x.Dockerfile b/ci/containers/libvirt-debian-10-cross-s390x.Dockerfile
index b8cd02ae69..01a5bb5a77 100644
--- a/ci/containers/libvirt-debian-10-cross-s390x.Dockerfile
+++ b/ci/containers/libvirt-debian-10-cross-s390x.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-10.Dockerfile b/ci/containers/libvirt-debian-10.Dockerfile
index de795d386c..2b1c1b9855 100644
--- a/ci/containers/libvirt-debian-10.Dockerfile
+++ b/ci/containers/libvirt-debian-10.Dockerfile
@@ -81,6 +81,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-aarch64.Dockerfile b/ci/containers/libvirt-debian-sid-cross-aarch64.Dockerfile
index a5d9a1d655..f573b8475a 100644
--- a/ci/containers/libvirt-debian-sid-cross-aarch64.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-aarch64.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-armv6l.Dockerfile b/ci/containers/libvirt-debian-sid-cross-armv6l.Dockerfile
index 9af186743f..2a9f81a15b 100644
--- a/ci/containers/libvirt-debian-sid-cross-armv6l.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-armv6l.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-armv7l.Dockerfile b/ci/containers/libvirt-debian-sid-cross-armv7l.Dockerfile
index 7e00d6c320..3e37184069 100644
--- a/ci/containers/libvirt-debian-sid-cross-armv7l.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-armv7l.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-i686.Dockerfile b/ci/containers/libvirt-debian-sid-cross-i686.Dockerfile
index d30468e8c6..e167a43b56 100644
--- a/ci/containers/libvirt-debian-sid-cross-i686.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-i686.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-mips64el.Dockerfile b/ci/containers/libvirt-debian-sid-cross-mips64el.Dockerfile
index 23399cb0f5..57ef04771e 100644
--- a/ci/containers/libvirt-debian-sid-cross-mips64el.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-mips64el.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-mipsel.Dockerfile b/ci/containers/libvirt-debian-sid-cross-mipsel.Dockerfile
index c4f70dbace..a174fb57fd 100644
--- a/ci/containers/libvirt-debian-sid-cross-mipsel.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-mipsel.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-ppc64le.Dockerfile b/ci/containers/libvirt-debian-sid-cross-ppc64le.Dockerfile
index 6c093efea8..d1c412c452 100644
--- a/ci/containers/libvirt-debian-sid-cross-ppc64le.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-ppc64le.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid-cross-s390x.Dockerfile b/ci/containers/libvirt-debian-sid-cross-s390x.Dockerfile
index e536587bc7..2dffc08895 100644
--- a/ci/containers/libvirt-debian-sid-cross-s390x.Dockerfile
+++ b/ci/containers/libvirt-debian-sid-cross-s390x.Dockerfile
@@ -45,6 +45,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-debian-sid.Dockerfile b/ci/containers/libvirt-debian-sid.Dockerfile
index 4e60303356..5b7b980419 100644
--- a/ci/containers/libvirt-debian-sid.Dockerfile
+++ b/ci/containers/libvirt-debian-sid.Dockerfile
@@ -81,6 +81,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
diff --git a/ci/containers/libvirt-fedora-31.Dockerfile b/ci/containers/libvirt-fedora-31.Dockerfile
index 40288a2d03..06bd1435d3 100644
--- a/ci/containers/libvirt-fedora-31.Dockerfile
+++ b/ci/containers/libvirt-fedora-31.Dockerfile
@@ -74,6 +74,7 @@ RUN dnf update -y && \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
diff --git a/ci/containers/libvirt-fedora-32.Dockerfile b/ci/containers/libvirt-fedora-32.Dockerfile
index ddb6378350..7b8a3fff44 100644
--- a/ci/containers/libvirt-fedora-32.Dockerfile
+++ b/ci/containers/libvirt-fedora-32.Dockerfile
@@ -74,6 +74,7 @@ RUN dnf update -y && \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
diff --git a/ci/containers/libvirt-fedora-rawhide-cross-mingw32.Dockerfile b/ci/containers/libvirt-fedora-rawhide-cross-mingw32.Dockerfile
index cdf61fe845..ac5ecc2958 100644
--- a/ci/containers/libvirt-fedora-rawhide-cross-mingw32.Dockerfile
+++ b/ci/containers/libvirt-fedora-rawhide-cross-mingw32.Dockerfile
@@ -3,97 +3,59 @@ FROM fedora:rawhide
RUN dnf update -y --nogpgcheck fedora-gpg-keys && \
dnf update -y && \
dnf install -y \
- audit-libs-devel \
augeas \
autoconf \
automake \
- avahi-devel \
bash \
bash-completion \
ca-certificates \
ccache \
chrony \
cppi \
- cyrus-sasl-devel \
- dbus-devel \
- device-mapper-devel \
dnsmasq \
dwarves \
ebtables \
- fuse-devel \
gcc \
gdb \
- gettext \
gettext-devel \
git \
- glib2-devel \
- glibc-devel \
glibc-langpack-en \
- glusterfs-api-devel \
- gnutls-devel \
iproute \
iproute-tc \
iscsi-initiator-utils \
kmod \
- libacl-devel \
- libattr-devel \
- libblkid-devel \
- libcap-ng-devel \
- libcurl-devel \
- libiscsi-devel \
- libnl3-devel \
- libpcap-devel \
- libpciaccess-devel \
- librbd-devel \
- libselinux-devel \
- libssh-devel \
- libssh2-devel \
- libtirpc-devel \
libtool \
- libudev-devel \
libwsman-devel \
libxml2 \
- libxml2-devel \
libxslt \
lsof \
lvm2 \
make \
meson \
- ncurses-devel \
net-tools \
- netcf-devel \
nfs-utils \
ninja-build \
- numactl-devel \
numad \
parted \
- parted-devel \
patch \
perl \
- pkgconfig \
polkit \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
radvd \
- readline-devel \
rpcgen \
rpm-build \
- sanlock-devel \
screen \
scrub \
sheepdog \
strace \
sudo \
- systemtap-sdt-devel \
vim \
- wireshark-devel \
- xen-devel \
- xfsprogs-devel \
- yajl-devel \
zfs-fuse && \
dnf autoremove -y && \
dnf clean all -y && \
@@ -109,9 +71,9 @@ RUN dnf install -y \
mingw32-gettext \
mingw32-glib2 \
mingw32-gnutls \
+ mingw32-headers \
mingw32-libssh2 \
mingw32-libxml2 \
- mingw32-openssl \
mingw32-pkg-config \
mingw32-portablexdr \
mingw32-readline && \
diff --git a/ci/containers/libvirt-fedora-rawhide-cross-mingw64.Dockerfile b/ci/containers/libvirt-fedora-rawhide-cross-mingw64.Dockerfile
index 2b7f9eeac1..e52e2fed04 100644
--- a/ci/containers/libvirt-fedora-rawhide-cross-mingw64.Dockerfile
+++ b/ci/containers/libvirt-fedora-rawhide-cross-mingw64.Dockerfile
@@ -3,97 +3,59 @@ FROM fedora:rawhide
RUN dnf update -y --nogpgcheck fedora-gpg-keys && \
dnf update -y && \
dnf install -y \
- audit-libs-devel \
augeas \
autoconf \
automake \
- avahi-devel \
bash \
bash-completion \
ca-certificates \
ccache \
chrony \
cppi \
- cyrus-sasl-devel \
- dbus-devel \
- device-mapper-devel \
dnsmasq \
dwarves \
ebtables \
- fuse-devel \
gcc \
gdb \
- gettext \
gettext-devel \
git \
- glib2-devel \
- glibc-devel \
glibc-langpack-en \
- glusterfs-api-devel \
- gnutls-devel \
iproute \
iproute-tc \
iscsi-initiator-utils \
kmod \
- libacl-devel \
- libattr-devel \
- libblkid-devel \
- libcap-ng-devel \
- libcurl-devel \
- libiscsi-devel \
- libnl3-devel \
- libpcap-devel \
- libpciaccess-devel \
- librbd-devel \
- libselinux-devel \
- libssh-devel \
- libssh2-devel \
- libtirpc-devel \
libtool \
- libudev-devel \
libwsman-devel \
libxml2 \
- libxml2-devel \
libxslt \
lsof \
lvm2 \
make \
meson \
- ncurses-devel \
net-tools \
- netcf-devel \
nfs-utils \
ninja-build \
- numactl-devel \
numad \
parted \
- parted-devel \
patch \
perl \
- pkgconfig \
polkit \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
radvd \
- readline-devel \
rpcgen \
rpm-build \
- sanlock-devel \
screen \
scrub \
sheepdog \
strace \
sudo \
- systemtap-sdt-devel \
vim \
- wireshark-devel \
- xen-devel \
- xfsprogs-devel \
- yajl-devel \
zfs-fuse && \
dnf autoremove -y && \
dnf clean all -y && \
@@ -109,9 +71,9 @@ RUN dnf install -y \
mingw64-gettext \
mingw64-glib2 \
mingw64-gnutls \
+ mingw64-headers \
mingw64-libssh2 \
mingw64-libxml2 \
- mingw64-openssl \
mingw64-pkg-config \
mingw64-portablexdr \
mingw64-readline && \
diff --git a/ci/containers/libvirt-fedora-rawhide.Dockerfile b/ci/containers/libvirt-fedora-rawhide.Dockerfile
index 28400a4e53..d3c97ddda0 100644
--- a/ci/containers/libvirt-fedora-rawhide.Dockerfile
+++ b/ci/containers/libvirt-fedora-rawhide.Dockerfile
@@ -75,6 +75,7 @@ RUN dnf update -y --nogpgcheck fedora-gpg-keys && \
python3 \
python3-docutils \
python3-flake8 \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-img \
diff --git a/ci/containers/libvirt-ubuntu-2004.Dockerfile b/ci/containers/libvirt-ubuntu-2004.Dockerfile
index 98178b1591..855b673f87 100644
--- a/ci/containers/libvirt-ubuntu-2004.Dockerfile
+++ b/ci/containers/libvirt-ubuntu-2004.Dockerfile
@@ -82,6 +82,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
policykit-1 \
python3 \
python3-docutils \
+ python3-pip \
python3-setuptools \
python3-wheel \
qemu-utils \
--
2.25.4
4 years, 5 months
[libvirt PATCH] qemu: ramfb video device doesn't support PCI address
by Jonathon Jongsma
Although a ramfb video device is not a PCI device, we don't currently
report an error for ramfb device definitions containing a PCI address.
However, a guest configured with such a device will fail to start:
# virsh start test1
error: Failed to start domain test1
error: internal error: qemu unexpectedly closed the monitor: 2020-06-16T05:23:02.759221Z qemu-kvm: -device ramfb,id=video0,bus=pcie.0,addr=0x1: Device 'ramfb' can't go on PCIE bus
A better approach is to reject any device definitions that contain PCI
addresses. While this is a change in behavior, any existing
configurations were non-functional.
https://bugzilla.redhat.com/show_bug.cgi?id=1847259
Signed-off-by: Jonathon Jongsma <jjongsma(a)redhat.com>
---
src/conf/domain_conf.c | 7 +++++++
tests/qemuxml2argvtest.c | 1 +
2 files changed, 8 insertions(+)
diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index fc7fcfb0c6..1a06cb3f4b 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -6608,6 +6608,13 @@ virDomainVideoDefValidate(const virDomainVideoDef *video,
return -1;
}
+ if (video->type == VIR_DOMAIN_VIDEO_TYPE_RAMFB &&
+ video->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) {
+ virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+ _("'address' is not supported for 'ramfb' video devices"));
+ return -1;
+ }
+
/* it doesn't make sense to pair video device type 'none' with any other
* types, there can be only a single video device in such case
*/
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 1195f9c982..f2522fa530 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -2276,6 +2276,7 @@ mymain(void)
QEMU_CAPS_VIRTIO_GPU_MAX_OUTPUTS);
DO_TEST_CAPS_LATEST("video-bochs-display-device");
DO_TEST_CAPS_LATEST("video-ramfb-display-device");
+ DO_TEST_CAPS_LATEST_PARSE_ERROR("video-ramfb-display-device-pci-address");
DO_TEST("video-none-device",
QEMU_CAPS_VNC);
DO_TEST_PARSE_ERROR("video-invalid-multiple-devices", NONE);
--
2.21.3
4 years, 5 months
[PATCH] qemuDomainDeviceNetDefPostParse: Switch order of conditions
by Michal Privoznik
A few commits back (in v6.4.0-131-gbdb8f2e418) the post parse
function for domain interface was changed so that it doesn't fill
in model for hostdev types of interfaces (including network type
interfaces which would end up hostdevs).
While the idea is sound, the execution can be a bit better:
virDomainNetResolveActualType() which is used to determine
runtime type of given interface is heavy gun - it connects to
network driver, fetches network XML, parses it. This all is
followed by check whether the interface doesn't already have
model set (from domain XML).
If we switch the order of these two checks then the short circuit
evaluation will ensure the expensive check is done only if really
needed.
This commit in fact fixes qemuxml2xmltest which due to lacking
fake network driver tries to connect to network:///session and
start the virtnetworkd. Fortunately, because of
v6.3.0-25-gf28fbb05d3 it fails to do so and
virDomainNetResolveActualType() returns -1. The only reason we
don't see the test failing is because our input XMLs have model
and thus we are saved by the latter (now former) check.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
While this patch is technically correct (the best way to be correct), it
can also be viewed as papering over the real issue. Question is, how to
address that. Nor xml2xml test nor xml2argv test are creating fake
network driver. Is mocking virDomainNetResolveActualType() the way to go
then? Or should we create the fake network driver with networks and
everything?
src/qemu/qemu_domain.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 2efbf1a4b3..c5b8d91f9a 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -5230,8 +5230,8 @@ qemuDomainDeviceNetDefPostParse(virDomainNetDefPtr net,
virQEMUCapsPtr qemuCaps)
{
if (net->type != VIR_DOMAIN_NET_TYPE_HOSTDEV &&
- virDomainNetResolveActualType(net) != VIR_DOMAIN_NET_TYPE_HOSTDEV &&
- !virDomainNetGetModelString(net))
+ !virDomainNetGetModelString(net) &&
+ virDomainNetResolveActualType(net) != VIR_DOMAIN_NET_TYPE_HOSTDEV)
net->model = qemuDomainDefaultNetModel(def, qemuCaps);
return 0;
--
2.26.2
4 years, 5 months