Re: [libvirt] [PATCH] usb: allow host devices to be specified by port
by Xen Mann
> [libvirt] [PATCH] usb: allow host devices to be specified by port
>
> ------------------------------------------------------------
>
> From: Thomas Hebb <thomas hebb editshare com>To: libvir-list redhat comCc: Thomas Hebb <thomas hebb editshare com>Subject: [libvirt] [PATCH] usb: allow host devices to be specified by portDate: Tue, 5 Jul 2016 17:21:24 -0400
> ------------------------------------------------------------
> Previously, only VID/PID and bus/device matching were supported. Neither
> of these provide a stable and persistent way of assigning a guest a
> specific host device out of several with the same VID and PID, as device
> numbers change on every enumeration.
Hey there,
is this patch already part of libvirt?
As mentioned by DanielB. (https://stackoverflow.com/questions/46421962/from-qemu-to-libvirtvirsh-ad...)
this feature is probably already implemented by now. If so, I really would like to use it, it would save me lot's of work.
Is this feature already part of libvirt? If it is already implemented, how can I use it?
If not, is this on schedule?
Thx in advance!
Xensemann
6 years, 10 months
[libvirt] [PATCH v4.1 0/2] qemu: Add support for hot unplugging redirdev
by Chen Hanxiao
v4.1:
call qemuDomainRemoveRedirdevDevice in qemuDomainRemoveDevice
v4:
update commit messages and news
v3:
use helper qemuDomainDelChardevTLSObjects and address some comments
v2:
rebased on master
Chen Hanxiao (2):
qemu: Add support for hot unplugging redirdev device which can use the
detach-device --live
news: add change of hot unplug redirdev
docs/news.xml | 5 +++
src/qemu/qemu_driver.c | 4 ++-
src/qemu/qemu_hotplug.c | 96 ++++++++++++++++++++++++++++++++++++++++++++++++-
src/qemu/qemu_hotplug.h | 4 +++
4 files changed, 107 insertions(+), 2 deletions(-)
--
2.14.3
6 years, 10 months
[libvirt] [PATCH] nodedev: Fix failing to parse PCI address for non-PCI network devices
by Fei Li
Commit 8708ca01c added virNetDevSwitchdevFeature to check whether
the NIC had Switchdev capabilities; however this causes errors for
network devices whose address is not in PCI format, like qeth device
whose address is 0.0.0800, when calling virPCIDeviceAddressParse.
Change virReportError to VIR_DEBUG to avoid these two error messages
occuring when starting the libvirtd service, just leave their callers
to handle the return values respectively.
Signed-off-by: Fei Li <fli(a)suse.com>
---
src/util/virpci.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/util/virpci.c b/src/util/virpci.c
index fe57bef32..880d7baba 100644
--- a/src/util/virpci.c
+++ b/src/util/virpci.c
@@ -2561,7 +2561,7 @@ logStrToLong_ui(char const *s,
ret = virStrToLong_ui(s, end_ptr, base, result);
if (ret != 0)
- VIR_ERROR(_("Failed to convert '%s' to unsigned int"), s);
+ VIR_DEBUG("Failed to convert '%s' to unsigned int", s);
return ret;
}
@@ -2638,9 +2638,7 @@ virPCIGetDeviceAddressFromSysfsLink(const char *device_link)
goto out;
if (virPCIDeviceAddressParse(config_address, bdf) < 0) {
- virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Failed to parse PCI config address '%s'"),
- config_address);
+ VIR_DEBUG("Failed to parse PCI config address '%s'", config_address);
VIR_FREE(bdf);
goto out;
}
--
2.13.5
6 years, 10 months
[libvirt] [PATCH] qemu: Prepare BIOS/UEFI when starting a domain
by Michal Privoznik
https://bugzilla.redhat.com/show_bug.cgi?id=1527740
Users might use a block device as UEFI VAR store. Or even have
OVMF stored there. Therefore, when starting a domain and separate
mount namespace is used, we have to create all the /dev entries
that are configured for the domain.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/qemu/qemu_domain.c | 41 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 41 insertions(+)
diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 43bd0fff4..04af68809 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -9470,6 +9470,44 @@ qemuDomainSetupAllRNGs(virQEMUDriverConfigPtr cfg,
}
+static int
+qemuDomainSetupLoader(virQEMUDriverConfigPtr cfg ATTRIBUTE_UNUSED,
+ virDomainObjPtr vm,
+ const struct qemuDomainCreateDeviceData *data)
+{
+ virDomainLoaderDefPtr loader = vm->def->os.loader;
+ int ret = -1;
+
+ VIR_DEBUG("Setting up loader");
+
+ if (loader) {
+ switch ((virDomainLoader) loader->type) {
+ case VIR_DOMAIN_LOADER_TYPE_ROM:
+ if (qemuDomainCreateDevice(loader->path, data, false) < 0)
+ goto cleanup;
+ break;
+
+ case VIR_DOMAIN_LOADER_TYPE_PFLASH:
+ if (qemuDomainCreateDevice(loader->path, data, false) < 0)
+ goto cleanup;
+
+ if (loader->nvram &&
+ qemuDomainCreateDevice(loader->nvram, data, false) < 0)
+ goto cleanup;
+ break;
+
+ case VIR_DOMAIN_LOADER_TYPE_LAST:
+ break;
+ }
+ }
+
+ VIR_DEBUG("Setup loader");
+ ret = 0;
+ cleanup:
+ return ret;
+}
+
+
int
qemuDomainBuildNamespace(virQEMUDriverConfigPtr cfg,
virSecurityManagerPtr mgr,
@@ -9538,6 +9576,9 @@ qemuDomainBuildNamespace(virQEMUDriverConfigPtr cfg,
if (qemuDomainSetupAllRNGs(cfg, vm, &data) < 0)
goto cleanup;
+ if (qemuDomainSetupLoader(cfg, vm, &data) < 0)
+ goto cleanup;
+
/* Save some mount points because we want to share them with the host */
for (i = 0; i < ndevMountsPath; i++) {
struct stat sb;
--
2.13.6
6 years, 10 months
[libvirt] [PATCH v3 0/5] Improvements to CPU frequency reporting
by Andrea Bolognani
Changes from [v2]:
* improve the parser;
* print the architecture name instead of "your architecture".
Changes from [v1]:
* adopt Bjoern's approach to refactoring.
[v2] https://www.redhat.com/archives/libvir-list/2017-December/msg00467.html
[v1] https://www.redhat.com/archives/libvir-list/2017-December/msg00356.html
Andrea Bolognani (4):
tests: Add host CPU data for Moonshot (RHEL 7.4)
util: Print architecture name in /proc/cpuinfo parser
util: Improve CPU frequency parsing
util: Don't report CPU frequency for ARM hosts
Bjoern Walk (1):
util: virhostcpu: factor out frequency parsing
src/Makefile.am | 1 +
src/util/virhostcpu.c | 188 ++++++++++++---------
.../linux-aarch64-rhel74-moonshot.cpuinfo | 72 ++++++++
.../linux-aarch64-rhel74-moonshot.expected | 1 +
.../linux-armv6l-raspberrypi.expected | 2 +-
.../linux-rhel74-moonshot/cpu/cpu0/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu0/online | 1 +
.../cpu/cpu0/topology/core_id | 1 +
.../cpu/cpu0/topology/core_siblings | 1 +
.../cpu/cpu0/topology/core_siblings_list | 1 +
.../cpu/cpu0/topology/physical_package_id | 1 +
.../cpu/cpu0/topology/thread_siblings | 1 +
.../cpu/cpu0/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu1/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu1/online | 1 +
.../cpu/cpu1/topology/core_id | 1 +
.../cpu/cpu1/topology/core_siblings | 1 +
.../cpu/cpu1/topology/core_siblings_list | 1 +
.../cpu/cpu1/topology/physical_package_id | 1 +
.../cpu/cpu1/topology/thread_siblings | 1 +
.../cpu/cpu1/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu2/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu2/online | 1 +
.../cpu/cpu2/topology/core_id | 1 +
.../cpu/cpu2/topology/core_siblings | 1 +
.../cpu/cpu2/topology/core_siblings_list | 1 +
.../cpu/cpu2/topology/physical_package_id | 1 +
.../cpu/cpu2/topology/thread_siblings | 1 +
.../cpu/cpu2/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu3/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu3/online | 1 +
.../cpu/cpu3/topology/core_id | 1 +
.../cpu/cpu3/topology/core_siblings | 1 +
.../cpu/cpu3/topology/core_siblings_list | 1 +
.../cpu/cpu3/topology/physical_package_id | 1 +
.../cpu/cpu3/topology/thread_siblings | 1 +
.../cpu/cpu3/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu4/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu4/online | 1 +
.../cpu/cpu4/topology/core_id | 1 +
.../cpu/cpu4/topology/core_siblings | 1 +
.../cpu/cpu4/topology/core_siblings_list | 1 +
.../cpu/cpu4/topology/physical_package_id | 1 +
.../cpu/cpu4/topology/thread_siblings | 1 +
.../cpu/cpu4/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu5/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu5/online | 1 +
.../cpu/cpu5/topology/core_id | 1 +
.../cpu/cpu5/topology/core_siblings | 1 +
.../cpu/cpu5/topology/core_siblings_list | 1 +
.../cpu/cpu5/topology/physical_package_id | 1 +
.../cpu/cpu5/topology/thread_siblings | 1 +
.../cpu/cpu5/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu6/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu6/online | 1 +
.../cpu/cpu6/topology/core_id | 1 +
.../cpu/cpu6/topology/core_siblings | 1 +
.../cpu/cpu6/topology/core_siblings_list | 1 +
.../cpu/cpu6/topology/physical_package_id | 1 +
.../cpu/cpu6/topology/thread_siblings | 1 +
.../cpu/cpu6/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/cpu7/node0 | 1 +
.../linux-rhel74-moonshot/cpu/cpu7/online | 1 +
.../cpu/cpu7/topology/core_id | 1 +
.../cpu/cpu7/topology/core_siblings | 1 +
.../cpu/cpu7/topology/core_siblings_list | 1 +
.../cpu/cpu7/topology/physical_package_id | 1 +
.../cpu/cpu7/topology/thread_siblings | 1 +
.../cpu/cpu7/topology/thread_siblings_list | 1 +
.../linux-rhel74-moonshot/cpu/kernel_max | 1 +
.../linux-rhel74-moonshot/cpu/offline | 1 +
.../linux-rhel74-moonshot/cpu/online | 1 +
.../linux-rhel74-moonshot/cpu/possible | 1 +
.../linux-rhel74-moonshot/cpu/present | 1 +
.../linux-rhel74-moonshot/node/has_cpu | 1 +
.../linux-rhel74-moonshot/node/has_memory | 1 +
.../linux-rhel74-moonshot/node/has_normal_memory | 1 +
.../linux-rhel74-moonshot/node/node0/cpu0 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu1 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu2 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu3 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu4 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu5 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu6 | 1 +
.../linux-rhel74-moonshot/node/node0/cpu7 | 1 +
.../linux-rhel74-moonshot/node/node0/cpulist | 1 +
.../linux-rhel74-moonshot/node/node0/cpumap | 1 +
.../linux-rhel74-moonshot/node/online | 1 +
.../linux-rhel74-moonshot/node/possible | 1 +
tests/virhostcpudata/linux-x86_64-test1.cpuinfo | 4 +
tests/virhostcputest.c | 1 +
91 files changed, 273 insertions(+), 80 deletions(-)
create mode 100644 tests/virhostcpudata/linux-aarch64-rhel74-moonshot.cpuinfo
create mode 100644 tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/thread_siblings_list
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/node0
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/physical_package_id
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/thread_siblings
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/thread_siblings_list
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/kernel_max
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/offline
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/possible
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/present
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/has_cpu
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/has_memory
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/has_normal_memory
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu0
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu1
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu2
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu3
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu4
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu5
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu6
create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu7
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpulist
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpumap
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/online
create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/possible
--
2.14.3
6 years, 10 months
[libvirt] [PATCH] virsh: Checking the volume capacity before uploading a new file.
by Julio Faracco
The current command 'vol-upload' is not checking if the volume accepts
a file bigger than its capacity. It can cause an interrupt of the
upload stream. This commit adds a check that fails before starting to
send new file to volume if the file is bigger.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1529059
Signed-off-by: Julio Faracco <jcfaracco(a)gmail.com>
---
tools/virsh-volume.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/tools/virsh-volume.c b/tools/virsh-volume.c
index 8265a39..1359dba 100644
--- a/tools/virsh-volume.c
+++ b/tools/virsh-volume.c
@@ -672,6 +672,7 @@ cmdVolUpload(vshControl *ctl, const vshCmd *cmd)
{
const char *file = NULL;
virStorageVolPtr vol = NULL;
+ virStorageVolInfo volumeInfo;
bool ret = false;
int fd = -1;
virStreamPtr st = NULL;
@@ -701,6 +702,9 @@ cmdVolUpload(vshControl *ctl, const vshCmd *cmd)
cbData.ctl = ctl;
cbData.fd = fd;
+ if (virStorageVolGetInfo(vol, &volumeInfo) < 0)
+ goto cleanup;
+
if (vshCommandOptBool(cmd, "sparse"))
flags |= VIR_STORAGE_VOL_UPLOAD_SPARSE_STREAM;
@@ -709,6 +713,11 @@ cmdVolUpload(vshControl *ctl, const vshCmd *cmd)
goto cleanup;
}
+ if (volumeInfo.capacity <= virFileLength(file, fd)) {
+ vshError(ctl, _("file is bigger than volume %s capacity"), name);
+ goto cleanup;
+ }
+
if (virStorageVolUpload(vol, st, offset, length, flags) < 0) {
vshError(ctl, _("cannot upload to volume %s"), name);
goto cleanup;
--
2.7.4
6 years, 10 months
[libvirt] [PATCH v2 0/2] Introducing testDomainRename().
by Julio Faracco
This commit introduces the testDomainRename() for test driver. It
includes:
- testDomainRename() implementation.
- Test case for virshtest to test 'domrename' command.
Julio Faracco (2):
test: Implementing testDomainRename().
tests: Adding test case for 'domrename' command inside virshtest.
src/test/test_driver.c | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++
tests/virshtest.c | 13 +++++++++
2 files changed, 85 insertions(+)
--
2.7.4
6 years, 10 months
[libvirt] [PATCH] domain_conf: skip boot order check of CD-ROM or floppy device
by Chen Hanxiao
From: Chen Hanxiao <chenhanxiao(a)gmail.com>
If we insert or eject a CD-ROM/floppy device with a boot order,
we may get:
unsupported configuration: boot order 2 is already used by another device
This check should be skipped in this case.
Signed-off-by: Chen Hanxiao <chenhanxiao(a)gmail.com>
---
src/conf/domain_conf.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index 9a62bc472..885ab88d2 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -26880,11 +26880,19 @@ virDomainDeviceInfoCheckBootIndex(virDomainDefPtr def ATTRIBUTE_UNUSED,
{
virDomainDeviceInfoPtr newinfo = opaque;
+ int disk_device = device->data.disk->device;
if (info->bootIndex == newinfo->bootIndex) {
- virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("boot order %u is already used by another device"),
- newinfo->bootIndex);
- return -1;
+ /* Skip check for insert or eject CD-ROM device */
+ if (disk_device == VIR_DOMAIN_DISK_DEVICE_FLOPPY ||
+ disk_device == VIR_DOMAIN_DISK_DEVICE_CDROM) {
+ VIR_DEBUG("Skip boot index check for floppy or CDROM");
+ return 0;
+ } else {
+ virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
+ _("boot order %u is already used by another device"),
+ newinfo->bootIndex);
+ return -1;
+ }
}
return 0;
}
--
2.14.3
6 years, 10 months
[libvirt] [PATCH v3 0/2] qemu: Add support for hot unplugging
by Chen Hanxiao
v3:
use helper qemuDomainDelChardevTLSObjects and address some comments
v2:
rebased on master
Chen Hanxiao (2):
qemu: Add support for hot unplugging redirdev device which can use the
detach-device --live
news: add change of hot unplug redirdev
docs/news.xml | 11 ++++++
src/qemu/qemu_driver.c | 4 ++-
src/qemu/qemu_hotplug.c | 91 +++++++++++++++++++++++++++++++++++++++++++++++++
src/qemu/qemu_hotplug.h | 4 +++
4 files changed, 109 insertions(+), 1 deletion(-)
--
2.14.3
6 years, 10 months
[libvirt] [PATCH v4 00/13] Move qemu command line controller checks to qemuDomainDeviceDefValidateController* checks
by John Ferlan
v3: https://www.redhat.com/archives/libvir-list/2017-December/msg00209.html
Differences since v3:
* Pushed first 4 ACK'd patches of v3
* Rework/Separate out a few patches for the SCSI handling
* Alter the PCI handling as requested by code review (although I still
had a question to a review comment regarding whether or not the model
should be handled in PostParse).
* Alter the SATA code as indicated by code review
* Add Andrea's patch into the series
Andrea Bolognani (1):
qemu: Add missing checks for pcie-root-port options
John Ferlan (12):
qemu: Introduce qemuDomainDeviceDefValidateControllerAttributes
qemu: Move model set for qemuBuildControllerDevStr
qemu: Adjust SCSI controller switch in qemuBuildControllerDevStr
qemu: Add check for iothread attribute in validate controller
qemu: Introduce qemuDomainDeviceDefValidateControllerSCSI
qemu: Introduce qemuDomainDeviceDefValidateControllerPCI
qemu: Use virDomainPCIControllerOpts in qemuBuildControllerDevStr
qemu: Move PCI command modelName check to controller def validate
qemu: Move PCI command modelName TypeToString to controller def
validate
qemu: Move PCI more command checks to controller def validate
qemu: Complete PCI command checks to controller def validate
qemu: Introduce qemuDomainDeviceDefValidateControllerSATA
src/qemu/qemu_command.c | 403 ++++------------------------------------------
src/qemu/qemu_domain.c | 420 +++++++++++++++++++++++++++++++++++++++++++++++-
tests/qemumemlocktest.c | 14 ++
tests/qemuxml2xmltest.c | 5 +-
4 files changed, 466 insertions(+), 376 deletions(-)
--
2.13.6
6 years, 10 months