Re: [PATCH 1/3] [bhyve] list pci devices on host

2025-02-11 Thread Alexander Shursha
Roman Bogorodskiy writes: > I think this change requires fixing the tests/domaincapstest. You can > run tests using 'ninja test'. Done > The util/virtpci.c is definitely not my area of knowledge, though it > feels like there's probably a more general way to make these changes. > Having differen

Re: [PATCH 2/3] [bhyve] add command line argument "passthru"

2025-02-11 Thread Akexander Shursha
Roman Bogorodskiy writes: > Alexander Shursha wrote: > >> Sponsored by: Future Crew, LLC >> Signed-off-by: Alexander Shursha >> --- >> src/bhyve/bhyve_command.c | 22 ++ >> 1 file changed, 22 insertions(+) >> >> diff --git a/src/bhyve/bhyve_command.c b/src/bhyve/bhyve_com

[PATCH 3/4] bhyve: add command line argument "passthru"

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/bhyve/bhyve_command.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/src/bhyve/bhyve_command.c b/src/bhyve/bhyve_command.c index bc287307c8..5da88ec9bd 100644 --- a/src/bhyve/bhyve_command.c

[PATCH 2/4] bhyve: list pci devices on host

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/bhyve/bhyve_capabilities.c | 2 +- src/conf/node_device_conf.c | 2 +- src/node_device/node_device_driver.c| 2 +- src/node_device/node_device_udev.c | 2 ++ src/util/virmdev.c

[PATCH 4/4] bhyve: parse passthru argument from XML-config

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/bhyve/bhyve_parse_command.c | 59 + 1 file changed, 59 insertions(+) diff --git a/src/bhyve/bhyve_parse_command.c b/src/bhyve/bhyve_parse_command.c index 29d3a678bf..14916c401d 100644 --- a/sr

[PATCH 1/4] virpci: changed the work with PCI via libpciaccess

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/meson.build | 1 + src/util/virpci.c | 464 ++-- tests/qemuhotplugtest.c | 11 +- tests/qemumemlocktest.c | 9 + tests/qemuxmlconftest.c | 9 + tests/virpcimock.c

[PATCH 4/4] bhyve: parse passthru argument from XML-config

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/bhyve/bhyve_parse_command.c | 59 + 1 file changed, 59 insertions(+) diff --git a/src/bhyve/bhyve_parse_command.c b/src/bhyve/bhyve_parse_command.c index 29d3a678bf..14916c401d 100644 --- a/sr

[PATCH 3/4] bhyve: add command line argument "passthru"

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/bhyve/bhyve_command.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/src/bhyve/bhyve_command.c b/src/bhyve/bhyve_command.c index bc287307c8..5da88ec9bd 100644 --- a/src/bhyve/bhyve_command.c

[PATCH 2/4] bhyve: list pci devices on host

2025-02-11 Thread Alexander Shursha
Sponsored by: Future Crew, LLC Signed-off-by: Alexander Shursha --- src/bhyve/bhyve_capabilities.c | 2 +- src/conf/node_device_conf.c | 2 +- src/node_device/node_device_driver.c| 2 +- src/node_device/node_device_udev.c | 2 ++ src/util/virmdev.c

[PATCH 17/17] conf: change virDomainDefAddImplicitControllers() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index c4bdf58788..21fe1502db 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -22341,

[PATCH 02/17] conf: change virDomainNetInsert() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 4 ++-- src/conf/domain_conf.h | 2 +- src/libxl/libxl_driver.c | 3 +-- src/lxc/lxc_driver.c | 3 +-- src/qemu/qemu_driver.c | 5 + 5 files changed, 6 insertions(+), 11 deletions(-) diff --git a/src/conf/domai

[PATCH 16/17] conf: change virDomainDefMaybeAddSmartcardController() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index fe816dfd6d..c4bdf58788 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -2230

[PATCH 15/17] conf: change virDomainDefMaybeAddVirtioSerialController() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index c056abb28f..fe816dfd6d 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -22270,

[PATCH 09/17] conf: stop checking for NULL return from virDomainDefAddController()

2025-02-11 Thread Laine Stump
It can't fail, so the caller doesn't need to check the return. Signed-off-by: Laine Stump --- src/conf/domain_conf.c| 25 + src/libxl/libxl_domain.c | 3 +-- src/qemu/qemu_postparse.c | 12 ++-- src/vbox/vbox_common.c| 13 ++--- src/vmx/vmx.c

[PATCH 14/17] conf: change virDomainDefAddDiskControllersForType() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 33 ++--- 1 file changed, 10 insertions(+), 23 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index d3e95a2f92..c056abb28f 100644 --- a/src/conf/domain_conf.c +++ b/src/

[PATCH 13/17] conf: change virDomainDefMaybeAddHostdevSCSIcontroller() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 611b6a44c8..d3e95a2f92 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -

[PATCH 11/17] hyperv: change hypervDomainDefAppendController() to return void

2025-02-11 Thread Laine Stump
It can't fail. And as a result, hypervDomainDefAppendSCSIController() and hypervDomainDefAppendIDEController() can also be changed to return void. Signed-off-by: Laine Stump --- src/hyperv/hyperv_driver.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a

[PATCH 10/17] conf: change virDomainDefAddUSBController() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c| 8 +++- src/conf/domain_conf.h| 2 +- src/qemu/qemu_postparse.c | 6 ++ 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 837b306919..5d887054

[PATCH 12/17] conf: change virDomainDefMaybeAddController() to return true/false

2025-02-11 Thread Laine Stump
This function can't fail, but it has always returned 1 if a controller is added and 0 if not, and there is one place that checks for a 1 return, so we remove the -1 return and change it to return true/false instead of 1/0. Signed-off-by: Laine Stump --- src/bhyve/bhyve_domain.c | 13 ++

[PATCH 08/17] conf: stop checking for NULL return from virDomainControllerDefNew()

2025-02-11 Thread Laine Stump
It can't fail, so the caller doesn't need to check the return. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 8 ++-- src/hyperv/hyperv_driver.c | 6 +- src/libxl/libxl_conf.c | 4 +--- src/libxl/libxl_driver.c | 5 + src/libxl/xen_xl.c | 4 +--- 5 files ch

[PATCH 07/17] conf: change qemuDomainDefAddImplicitInputDevice() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/qemu/qemu_postparse.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/qemu/qemu_postparse.c b/src/qemu/qemu_postparse.c index 53151eef75..0de48916f4 100644 --- a/src/qemu/qemu_postparse.c +++ b/src/qemu/qemu_postpar

[PATCH 06/17] libxl: change xenDomainDefAddImplicitInputDevice() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/libxl/libxl_domain.c | 3 +-- src/libxl/xen_common.c | 4 +--- src/libxl/xen_common.h | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/libxl/libxl_domain.c b/src/libxl/libxl_domain.c index 6805160923..c7ba5636c4 1006

[PATCH 05/17] conf: change virDomainDefMaybeAddInput() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c| 6 ++ src/conf/domain_conf.h| 2 +- src/libxl/xen_common.c| 11 ++- src/qemu/qemu_postparse.c | 27 ++- src/vz/vz_driver.c| 11 ++- src/vz/vz_sdk.c |

[PATCH 00/17] conf/qemu/etc: change several functions to return void instead of 0/-1

2025-02-11 Thread Laine Stump
This started with me noticing one function call that checked for failure on something that I knew couldn't fail. So I changed that function to return void. But then I noticed another similar function that also should return void, so I changed that one too. Then eliminating the check for the return

[PATCH 04/17] conf: change virDomainShmemDefInsert() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 4 +--- src/conf/domain_conf.h | 4 ++-- src/qemu/qemu_driver.c | 3 +-- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index b5b15b7768..2e74f75a13 100644 --- a

[PATCH 03/17] conf: change virDomainFSInsert() to return void

2025-02-11 Thread Laine Stump
It can't fail. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 4 +--- src/conf/domain_conf.h | 2 +- src/qemu/qemu_driver.c | 3 +-- src/vz/vz_sdk.c| 3 +-- 4 files changed, 4 insertions(+), 8 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 18820

[PATCH 01/17] conf: change virDomainHostdevInsert() to return void

2025-02-11 Thread Laine Stump
We haven't checked for memalloc failure in many years, and that was the only reason this function would have ever failed. Signed-off-by: Laine Stump --- src/conf/domain_conf.c | 15 +-- src/conf/domain_conf.h | 2 +- src/libxl/libxl_domain.c | 5 + src/libxl/libxl_driver.c

[PATCH v3 2/2] ch: Enable SEV SNP support

2025-02-11 Thread Praveen K Paladugu
Enable SEV-SNP support for ch guests. Co-Authored-by: Smit Gardhariya Signed-off-by: Praveen K Paladugu --- src/ch/ch_monitor.c | 65 - 1 file changed, 53 insertions(+), 12 deletions(-) diff --git a/src/ch/ch_monitor.c b/src/ch/ch_monitor.c index bed

[PATCH v3 1/2] util: Introduce virStringFormatHex

2025-02-11 Thread Praveen K Paladugu
virStringFormatHex converts an input byte array into hex string and returns it. Signed-off-by: Praveen K Paladugu --- src/libvirt_private.syms | 1 + src/util/virstring.c | 19 +++ src/util/virstring.h | 1 + 3 files changed, 21 insertions(+) diff --git a/src/libvirt_p

[PATCH v3 0/2] Enable SEV SNP support in ch driver

2025-02-11 Thread Praveen K Paladugu
This version introduces virStringFormatHex method and uses this method while sending host_data to cloud-hypervisor. Praveen K Paladugu (2): util: Introduce virStringFormatHex ch: Enable SEV SNP support src/ch/ch_monitor.c | 65 src/libvirt_priva

[PATCH] ci: refresh with 'lcitool manifest'

2025-02-11 Thread Daniel P . Berrangé
This replaces Fedora 39 with Fedora 41, updates the FreeBSD Cirrus CI image names, and tweaks some package names Signed-off-by: Daniel P. Berrangé --- NB: this updates the integration test config files but the integration test machine lacks updates. I have disabled running of integration tests i

Re: Support for: VIR_DOMAIN_EVENT_ID_DBGTOOLS.

2025-02-11 Thread Daniel P . Berrangé
On Fri, Feb 07, 2025 at 02:34:34PM +, Martin Harvey wrote: > Probably a FAQ. > > I have implemented a prototype: > > * > QEMU event for an in-guest issue (tools installation / crash etc), via fwcfg > / vmcore (similar). (QEMU_PROCESS_EVENT_DBGTOOLS_CHANGED). > * > Qemu Process / QemuMoni

Re: Support for: VIR_DOMAIN_EVENT_ID_DBGTOOLS.

2025-02-11 Thread Martin Harvey
> I don't think this is achievable via EVENT_TUNABLE. > If you need to detect changes made by guest OS in fwcfg then we need > QEMU to send an event to libvirt so that it can be relayed to users. I have already implemented in a local nutanix branch - I may be throwing a patch set at them soon.

[PATCH 1/5] qemu-replies-tool: Dump also query string for optional members

2025-02-11 Thread Peter Krempa
The query language allows querying whether a member is optional by using the '*' "operator" but the dumper script didn't output those query strings. Signed-off-by: Peter Krempa --- scripts/qemu-replies-tool.py | 4 1 file changed, 4 insertions(+) diff --git a/scripts/qemu-replies-tool.py b

Re: [PATCH v5 07/18] remote: New APIs for ThrottleGroup lifecycle management

2025-02-11 Thread Peter Krempa
On Mon, Feb 10, 2025 at 11:16:54 -, Harikumar Rajkumar wrote: > > On Fri, Feb 07, 2025 at 04:59:49 -, Harikumar Rajkumar wrote: > > It is an implementation detail how that is achieved, based on what qemu > > provides: > > - explicitly request qemu to revert to default > > - query th

[PATCH 5/5] qemu: migration: Reactivate block nodes after migration if VM is left paused

2025-02-11 Thread Peter Krempa
On incoming migration qemu doesn't activate the block graph nodes right away. This is to properly facilitate locking of the images. The block nodes are normally re-activated when starting the CPUs after migration, but in cases (e.g. when a paused VM was migrated) when the VM is left paused the blo

[PATCH 4/5] qemu: monitor: Add monitor backend for 'blockdev-set-active'

2025-02-11 Thread Peter Krempa
The command will be used to re-activate block nodes after migration when we're leaving the VM paused so that blockjobs can be used. As the 'node-name' field is optional the 'qemumonitorjsontest' case tests both variants. Signed-off-by: Peter Krempa --- src/qemu/qemu_monitor.c | 21

[PATCH 3/5] qemu: capabilies: Introduce QEMU_CAPS_BLOCKDEV_SET_ACTIVE

2025-02-11 Thread Peter Krempa
The flag signals presence of the 'blockdev-set-active' QMP command. Signed-off-by: Peter Krempa --- src/qemu/qemu_capabilities.c | 2 ++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_10.0.0_x86_64.xml | 1 + 3 files changed, 4 inser

[PATCH 0/5] qemu: migration: Reactivate block nodes after migration if VM is left paused

2025-02-11 Thread Peter Krempa
Patch 1/5 is a bugfix for the qemu-replies-tool. For justification of 2-5/5 see 5/5. Peter Krempa (5): qemu-replies-tool: Dump also query string for optional members qemucapabilitiestest: Update 'caps_10.0.0_x86_64' to 'v9.2.0-1636-gffaf7f0376' qemu: capabilies: Introduce QEMU_CAPS_BLOC

Re: Support for: VIR_DOMAIN_EVENT_ID_DBGTOOLS.

2025-02-11 Thread Michal Prívozník
On 2/7/25 15:34, Martin Harvey wrote: > Probably a FAQ. > > I have implemented a prototype: > > * > QEMU event for an in-guest issue (tools installation / crash etc), > via fwcfg / vmcore (similar). (QEMU_PROCESS_EVENT_DBGTOOLS_CHANGED). > * > Qemu Process / QemuMonitor handling f

Re: [PATCH] cpu_map: Add missing feature "bhi-no"

2025-02-11 Thread Michal Prívozník
On 2/7/25 15:39, Tim Wiederhake wrote: > Introduced in qemu commit b611931d4f70b9a3e49e39c405c63b3b5e9c0df1. > > Signed-off-by: Tim Wiederhake > --- > src/cpu_map/x86_features.xml | 3 +++ > 1 file changed, 3 insertions(+) > Reviewed-by: Michal Privoznik Michal