Re: [PATCH] qemu: Move some enums impl to qemu_monitor.c

2022-02-21 Thread Michal Prívozník
On 2/21/22 17:17, Andrea Bolognani wrote: > On Mon, Feb 21, 2022 at 04:10:25PM +0100, Michal Privoznik wrote: >> +VIR_ENUM_IMPL(qemuMonitorCPUProperty, >> + QEMU_MONITOR_CPU_PROPERTY_LAST, >> + "boolean", >> + "string", >> + "number", >> +); >>

Re: [PATCH v2 09/29] qemu: introduce QEMU_CAPS_DEVICE_PNV_PHB3

2022-02-21 Thread Daniel Henrique Barboza
On 2/21/22 10:07, Ján Tomko wrote: On a Tuesday in 2022, Daniel Henrique Barboza wrote: QEMU_CAPS_DEVICE_PNV_PHB3 indicates binary support for the pnv-phb3 device, the pcie-root controller for PowerNV8 domains, and also the pnv-phb3-root-port device, its pcie-root-port device. This

Re: [PATCH v2 01/29] qemu_domain.c: add PowerNV machine helpers

2022-02-21 Thread Daniel Henrique Barboza
On 2/21/22 09:47, Ján Tomko wrote: On a Tuesday in 2022, Daniel Henrique Barboza wrote: The PowerNV (Power Non-Virtualized) QEMU ppc64 machine is the emulation of a bare-metal IBM Power host.  It follows the OPAL (OpenPower Abstration Layer) API/ABI, most specifically Skiboot [1]. For now,

Re: Libvirt Rust bindings could use some work

2022-02-21 Thread Daniel P . Berrangé
On Mon, Feb 21, 2022 at 05:28:24PM +0100, Wim de With wrote: > On Mon, Feb 21, 2022 at 10:21:32AM -0500, Andrea Bolognani wrote: > > We are aware of the issues with the current API of libvirt-rs, but > > unfortunately nobody has been able to dedicate time to addressing > > them. Any contributions

Re: Libvirt Rust bindings could use some work

2022-02-21 Thread Daniel P . Berrangé
On Mon, Feb 21, 2022 at 10:21:32AM -0500, Andrea Bolognani wrote: > On Fri, Feb 18, 2022 at 10:28:29AM +0100, Wim de With wrote: > > Hello, > > > > I was reading the Rust bindings for libvirt and I noticed that they are > > not very idiomatic. A couple of examples: > > > > 1. It is conventional to

Re: [PATCH] qemu: Move some enums impl to qemu_monitor.c

2022-02-21 Thread Andrea Bolognani
On Mon, Feb 21, 2022 at 04:10:25PM +0100, Michal Privoznik wrote: > +VIR_ENUM_IMPL(qemuMonitorCPUProperty, > + QEMU_MONITOR_CPU_PROPERTY_LAST, > + "boolean", > + "string", > + "number", > +); > > VIR_ENUM_IMPL(qemuMonitorMigrationStatus, >

Re: Libvirt Rust bindings could use some work

2022-02-21 Thread Andrea Bolognani
On Mon, Feb 21, 2022 at 04:30:28PM +0100, Ján Tomko wrote: > On a Monday in 2022, Andrea Bolognani wrote: > > On Fri, Feb 18, 2022 at 10:28:29AM +0100, Wim de With wrote: > > Licensing is a pretty fun minefield :) > > > > For example, even though libvirt-rs itself would be statically linked > >

Re: Libvirt Rust bindings could use some work

2022-02-21 Thread Ján Tomko
On a Monday in 2022, Andrea Bolognani wrote: On Fri, Feb 18, 2022 at 10:28:29AM +0100, Wim de With wrote: Licensing is a pretty fun minefield :) For example, even though libvirt-rs itself would be statically linked into any application that uses it, by virtue of it being a wrapper around the C

Re: Call for GSoC and Outreachy project ideas for summer 2022

2022-02-21 Thread Michal Prívozník
On 2/21/22 12:27, Paolo Bonzini wrote: > On 2/21/22 10:36, Michal Prívozník wrote: >> Indeed. Libvirt's participating on its own since 2016, IIRC. Since we're >> still in org acceptance phase we have some time to decide this, >> actually. We can do the final decision after participating orgs are

Re: Libvirt Rust bindings could use some work

2022-02-21 Thread Andrea Bolognani
On Fri, Feb 18, 2022 at 10:28:29AM +0100, Wim de With wrote: > Hello, > > I was reading the Rust bindings for libvirt and I noticed that they are > not very idiomatic. A couple of examples: > > 1. It is conventional to have a *-sys crate containing only the C > interface and the linking

[PATCH] qemu: Move some enums impl to qemu_monitor.c

2022-02-21 Thread Michal Privoznik
There are some enums that are declared in qemu_monitor.h but implemented in qemu_monitor_json.c. While from compiler and linker POV it doesn't matter, the code is cleaner if an enum is implemented in .c file that corresponds to .h file which declared the enum. Signed-off-by: Michal Privoznik ---

Re: [PATCH] NEWS: Document domain dirty page rate calculation APIs

2022-02-21 Thread Michal Prívozník
On 2/21/22 14:30, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > The Libvirt API virDomainStartDirtyRateCalc was extended. > Document this change. > > Signed-off-by: Hyman Huang(黄勇) > --- > NEWS.rst | 14 ++ > 1 file changed, 14 insertions(+) Reviewed-by: Michal

Re: [PATCH] qemu: Use virDomainObjCheckActive() more

2022-02-21 Thread Michal Prívozník
On 2/21/22 14:27, Ján Tomko wrote: > On a Monday in 2022, Michal Privoznik wrote: >> Using the following spatch, I've identified two places which >> could be switched from explicit virDomainObjIsActive() + >> virReportError() to virDomainObjCheckActive(): >> >>  @@ >>  expression dom; >>  @@ >>    

Re: [PATCH v2 26/29] domain_conf.c: add phb4-root-port to IsPowerNVRootPort()

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Make the virDomainControllerIsPowerNVRootPort() helper recognize pnv-phb4-root-port as a PowerNV root port. This will spare us from duplicating checks where the constraints of pnv-phb3-root-port also applies for the pnv-phb4-root-port device.

Re: [PATCH v2 25/29] conf, qemu: add 'pnv-phb4-root-port' PCI controller model name

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: This device is an implementation of pcie-root-port, similar to its sibling pnv-phb3-root-port. Since it's a new model name that Libvirt automatically sets, we refrain from documenting it to users. Signed-off-by: Daniel Henrique Barboza ---

Re: [PATCH v2 18/29] qemu_command.c: add command line for the pnv-phb3 device

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: The command line for the pnv-phb3 device is similar to the spapr-pci-host-bridge command line but adding the extra 'chip-id' attribute. Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_command.c | 21

Re: [PATCH v2 20/29] domain_conf: format pnv-phb3-root-port empty addr

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Hiding the empty (:00:0.0) PCI address in the case of devices that will connect to slot 0x0 can be counterintuitive to the user, which will see something like this: Even if the user deliberately adds the root-port

Re: [PATCH v2 21/29] tests: add pnv-phb3-root-port test

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Signed-off-by: Daniel Henrique Barboza --- .../powernv8-root-port.ppc64-latest.args | 35 + tests/qemuxml2argvdata/powernv8-root-port.xml | 17 tests/qemuxml2argvtest.c | 1 +

[PATCH] NEWS: Document domain dirty page rate calculation APIs

2022-02-21 Thread huangy81
From: Hyman Huang(黄勇) The Libvirt API virDomainStartDirtyRateCalc was extended. Document this change. Signed-off-by: Hyman Huang(黄勇) --- NEWS.rst | 14 ++ 1 file changed, 14 insertions(+) diff --git a/NEWS.rst b/NEWS.rst index f545325..b684416 100644 --- a/NEWS.rst +++ b/NEWS.rst

Re: [PATCH v2 27/29] conf, qemu: add 'pnv-phb4' controller model name

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Similar to the existing pnv-phb3 device, pnv-phb4 is also an implementation of pcie-root. No user doc is needed in this case since the user doesn't ideally set PCI model names manually. Signed-off-by: Daniel Henrique Barboza ---

Re: [PATCH v2 28/29] domain_conf.c: add pnv-phb4 to ControllerIsPowerNVPHB()

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Update the virDomainControllerIsPowerNVPHB() helper to make the pnv-phb4 device receive the same handling as the existing pnv-phb3. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 3 ++- 1 file changed, 2 insertions(+), 1

Re: [PATCH v2 29/29] tests: add PowerNV9 tests

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Since the nuances of PowerNV PHBs and root ports were already handled when adding support for pnv-phb3* devices, we're already set to support PowerNV9 PHBs and root ports as well. Signed-off-by: Daniel Henrique Barboza ---

Re: [PATCH] qemu: Use virDomainObjCheckActive() more

2022-02-21 Thread Ján Tomko
On a Monday in 2022, Michal Privoznik wrote: Using the following spatch, I've identified two places which could be switched from explicit virDomainObjIsActive() + virReportError() to virDomainObjCheckActive(): @@ expression dom; @@ if ( -!virDomainObjIsActive(dom) +

Re: [PATCH v2 15/29] introduce virDomainControllerIsPowerNVPHB

2022-02-21 Thread Ján Tomko
Missing conf: prefix On a Tuesday in 2022, Daniel Henrique Barboza wrote: Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 21 + src/conf/domain_conf.h | 1 + src/libvirt_private.syms | 1 + 3 files changed, 23 insertions(+) Reviewed-by: Ján Tomko

Re: [PATCH v2 16/29] conf, qemu: add default 'chip-id' value for pnv-phb3 controllers

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: If ommited from the controller definition, chip-id defaults to zero. Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_domain_address.c | 16 +++- src/qemu/qemu_validate.c | 5

Re: [PATCH v2 14/29] formatdomain.rst: add 'index' semantics for PowerNV domains

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: We're going to use the 'targetIndex' element for PowerNV PHBs. Clarify that the same attribute will have a different meaning in this context. Signed-off-by: Daniel Henrique Barboza --- docs/formatdomain.rst | 6 -- 1 file changed, 4

Re: [PATCH v2 13/29] conf: parse and format

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: The 'chip-id' attribute indicates which chip/socket that owns the PowerNV pcie-root controller. Reviewed-by: Peter Krempa Signed-off-by: Daniel Henrique Barboza --- docs/formatdomain.rst | 6 ++ docs/schemas/domaincommon.rng |

Re: [PATCH v2 12/29] domain_conf.c: fix identation in virDomainControllerDefParseXML()

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: The identation of VIR_DOMAIN_CONTROLLER_TYPE_PCI elements are in the same level as the parent 'if (def->type == ...TYPE_PCI)' clause, and the closing bracket of this 'if' looks like a misplaced bracket of the 'targetIndex' clause that comes

Re: [PATCH v2 11/29] conf, qemu: add 'pnv-phb3' PCI controller model name

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Add support for the pcie-root implementation that PowerNV8 domains uses, pnv-phb3. It consists of a PCI model name that isn't supposed to be changed by users, so no doc changes in formatdomain.rst were made. Signed-off-by: Daniel Henrique

Re: [PATCH v2 10/29] conf, qemu: add 'pnv-phb3-root-port' PCI controller model name

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Apart from being usable only with pnv-phb3 PCIE host bridges (to be added soon), this device acts as a regular pcie-root-port but with a specific model name. No doc changes in formatdomain.rst were made because the PCI model name isn't

[PATCH] qemu: Use virDomainObjCheckActive() more

2022-02-21 Thread Michal Privoznik
Using the following spatch, I've identified two places which could be switched from explicit virDomainObjIsActive() + virReportError() to virDomainObjCheckActive(): @@ expression dom; @@ if ( -!virDomainObjIsActive(dom) +virDomainObjCheckActive(dom) < 0 ) {

Re: [PATCH v2 09/29] qemu: introduce QEMU_CAPS_DEVICE_PNV_PHB3

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: QEMU_CAPS_DEVICE_PNV_PHB3 indicates binary support for the pnv-phb3 device, the pcie-root controller for PowerNV8 domains, and also the pnv-phb3-root-port device, its pcie-root-port device. This capability is present in QEMU since 5.0.0 but

Re: [PATCH v6 0/8] support mode option for dirtyrate calculation

2022-02-21 Thread Hyman Huang
在 2022/2/21 20:35, Michal Prívozník 写道: On 2/20/22 14:28, huang...@chinatelecom.cn wrote: From: Hyman Huang(黄勇) v6: - rebase on mastr - drop the commit [PATCH v5 1/9] in this patchset, post an extra commit if needed in the future. Please review, thanks ! Regards Yong v5: - [PATCH v5

Re: [PATCH v6 7/8] virsh: Add mode option to domdirtyrate-calc virsh api

2022-02-21 Thread Hyman Huang
在 2022/2/21 20:34, Michal Prívozník 写道: On 2/20/22 14:28, huang...@chinatelecom.cn wrote: From: Hyman Huang(黄勇) Extend domdirtyrate-calc virsh api with mode option, either of these three options "page-sampling,dirty-bitmap,dirty-ring" can be specified when calculating dirty page rate.

Re: [PATCH v2 06/29] qemu_validate.c: enhance 'machine type not supported' message

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Add 'virt type' to allow for an easier time debugging. Reviewed-by: Peter Krempa Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_validate.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) Reviewed-by: Ján Tomko Jano

Re: [PATCH v2 05/29] qemu_domain.c: define ISA as default PowerNV serial

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: The PowerNV machines uses ISA as the default serial type. Reviewed-by: Peter Krempa Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_domain.c | 2 ++ 1 file changed, 2 insertions(+) Reviewed-by: Ján Tomko Jano signature.asc

Re: [PATCH v6 2/8] qemu_driver: Probe capability before calculating dirty page rate

2022-02-21 Thread Hyman Huang
在 2022/2/21 20:34, Michal Prívozník 写道: On 2/20/22 14:28, huang...@chinatelecom.cn wrote: From: Hyman Huang(黄勇) Probing QEMU_CAPS_CALC_DIRTY_RATE capability in advance in case of failure when calculating dirty page rate. Signed-off-by: Hyman Huang(黄勇) --- src/qemu/qemu_driver.c | 8

Re: [PATCH v2 08/29] tests: add basic PowerNV8 test

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: We're now able to boot a simple PowerNV8 domain in Libvirt. *libvirt Signed-off-by: Daniel Henrique Barboza --- .../powernv8-basic.ppc64-latest.args | 33 +++ tests/qemuxml2argvdata/powernv8-basic.xml | 16

Re: [PATCH v2 07/29] qemu_domain.c: disable default devices for PowerNV machines

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: PowerNV domains will support pcie-root devices as PHBs, in a similar fashion as pSeries domains supports the spapr-pci-host-bridge as a pci-root model. Set 'addPCIRoot' to false since we'll not be using this buses in this machine.

Re: [PATCH v2 04/29] qemu_validate.c: use qemuDomainIsPowerPC() in qemuValidateDomainChrDef()

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Both PowerNV and pSeries machines don't support parallel ports. Reviewed-by: Peter Krempa Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_validate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Ján Tomko

Re: [PATCH v2 03/29] qemu_domain: turn qemuDomainMachineIsPSeries() static

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: The function is now unused outside of qemu_domain.c. Reviewed-by: Peter Krempa Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_domain.c | 2 +- src/qemu/qemu_domain.h | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-)

Re: [PATCH v2 02/29] qemu_capabilities.c: use 'MachineIsPowerPC' in DeviceDiskCaps

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: Both pSeries and PowerNV machines don't have floppy device support. Reviewed-by: Peter Krempa Signed-off-by: Daniel Henrique Barboza --- src/qemu/qemu_capabilities.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Reviewed-by:

Re: [PATCH v2 01/29] qemu_domain.c: add PowerNV machine helpers

2022-02-21 Thread Ján Tomko
On a Tuesday in 2022, Daniel Henrique Barboza wrote: The PowerNV (Power Non-Virtualized) QEMU ppc64 machine is the emulation of a bare-metal IBM Power host. It follows the OPAL (OpenPower Abstration Layer) API/ABI, most specifically Skiboot [1]. For now, Libvirt has support for the pSeries QEMU

Re: [PATCH v6 4/8] include: Introduce virDomainDirtyRateCalcFlags

2022-02-21 Thread Michal Prívozník
On 2/20/22 14:28, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > Introduce virDomainDirtyRateCalcFlags to get ready for > adding mode parameter to qemuDomainStartDirtyRateCalc. > > Signed-off-by: Hyman Huang(黄勇) > --- > include/libvirt/libvirt-domain.h | 13 + > 1

Re: [PATCH v6 0/8] support mode option for dirtyrate calculation

2022-02-21 Thread Michal Prívozník
On 2/20/22 14:28, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > v6: > - rebase on mastr > - drop the commit [PATCH v5 1/9] in this patchset, post an extra > commit if needed in the future. > > Please review, thanks ! > > Regards > Yong > > v5: > - [PATCH v5 9/9]: Fix

Re: [PATCH v6 8/8] qemu_driver: Add calc_mode for dirtyrate statistics

2022-02-21 Thread Michal Prívozník
On 2/20/22 14:28, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > Add calc_mode for dirtyrate statistics retured by > virsh domstats --dirtyrate api, also add vcpu dirtyrate > if dirty-ring mode was used in last measurement. > > Signed-off-by: Hyman Huang(黄勇) > --- >

Re: [PATCH v6 2/8] qemu_driver: Probe capability before calculating dirty page rate

2022-02-21 Thread Michal Prívozník
On 2/20/22 14:28, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > Probing QEMU_CAPS_CALC_DIRTY_RATE capability in advance > in case of failure when calculating dirty page rate. > > Signed-off-by: Hyman Huang(黄勇) > --- > src/qemu/qemu_driver.c | 8 +++- > 1 file changed, 7

Re: [PATCH v6 7/8] virsh: Add mode option to domdirtyrate-calc virsh api

2022-02-21 Thread Michal Prívozník
On 2/20/22 14:28, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > Extend domdirtyrate-calc virsh api with mode option, either > of these three options "page-sampling,dirty-bitmap,dirty-ring" > can be specified when calculating dirty page rate. > > Signed-off-by: Hyman Huang(黄勇) >

Re: [PATCH v2 00/29] ppc64 PowerNV machines support

2022-02-21 Thread Daniel Henrique Barboza
Ping On 1/25/22 17:48, Daniel Henrique Barboza wrote: Hi, This v2 has changes proposed by Peter and Daniel on the v1 review. Peter's reviewed-by tags were kept when applicable. The usability change made is that, now, we'll fail to launch powernv domains that has a pnv-phb* device and it's

Re: [PATCH v2 0/4] qemu: Introduce 'virDomainQemuMonitorCommandWithFiles'

2022-02-21 Thread Ján Tomko
On a Monday in 2022, Peter Krempa wrote: I was doing some tests with 'add-fd' and 'getfd' and made this to help me. v2: - add API support for passing FDs back, but for now we don't have use for it Peter Krempa (4): virnetmessage: Introduce virNetMessageClearFDs lib: Introduce

Re: Call for GSoC and Outreachy project ideas for summer 2022

2022-02-21 Thread Paolo Bonzini
On 2/21/22 10:36, Michal Prívozník wrote: Indeed. Libvirt's participating on its own since 2016, IIRC. Since we're still in org acceptance phase we have some time to decide this, actually. We can do the final decision after participating orgs are announced. My gut feeling says that it's going to

Re: [PATCH v5 1/9] qemu: Refactor dirty page rate calculation status implementation

2022-02-21 Thread Daniel P . Berrangé
On Thu, Feb 17, 2022 at 05:19:32PM +0100, Michal Prívozník wrote: > On 2/16/22 01:28, huang...@chinatelecom.cn wrote: > > From: Hyman Huang(黄勇) > > > > For any virTypedParameter API normal practice is to use a string > > to expose the data, not the rather enum integer value. > > > > So let's

Re: Call for GSoC and Outreachy project ideas for summer 2022

2022-02-21 Thread Michal Prívozník
On 2/19/22 14:46, Stefan Hajnoczi wrote: > On Fri, 18 Feb 2022 at 16:03, Paolo Bonzini wrote: >> >> On 2/18/22 12:39, Michal Prívozník wrote: >>> On 2/17/22 18:52, Paolo Bonzini wrote: I would like to co-mentor one or more projects about adding more statistics to Mark Kanda's newly-born

Re: [libvirt PATCH] docs: Fix template matching in page.xsl

2022-02-21 Thread Michal Prívozník
On 2/21/22 09:42, Martin Kletzander wrote: > Our last default template had a match of "node()" which incidentally matched > everything, including text nodes. Since this has the same priority according > to > the XSLT spec, section 5.5: > > https://www.w3.org/TR/1999/REC-xslt-19991116#conflict

[libvirt PATCH] docs: Fix template matching in page.xsl

2022-02-21 Thread Martin Kletzander
Our last default template had a match of "node()" which incidentally matched everything, including text nodes. Since this has the same priority according to the XSLT spec, section 5.5: https://www.w3.org/TR/1999/REC-xslt-19991116#conflict this is an error. Also according to the same spec

[PATCH v2 3/4] virsh: Implement support for virDomainQemuMonitorCommandWithFiles

2022-02-21 Thread Peter Krempa
Signed-off-by: Peter Krempa --- docs/manpages/virsh.rst | 6 +- tools/virsh-domain.c| 19 ++- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/docs/manpages/virsh.rst b/docs/manpages/virsh.rst index 429879d2dd..1e6914a438 100644 ---

[PATCH v2 4/4] qemu: Implement qemuDomainQemuMonitorCommandWithFiles

2022-02-21 Thread Peter Krempa
Add support for sending one FD from the client along with a monitor command so that it's possible to use 'getfd' and 'add-fd' to use FDs passed from the client with other QMP commands. Signed-off-by: Peter Krempa --- src/qemu/qemu_driver.c | 42

[PATCH v2 2/4] lib: Introduce 'virDomainQemuMonitorCommandWithFiles'

2022-02-21 Thread Peter Krempa
This API has the same semantics as 'virDomainQemuMonitorCommand' but accepts file descriptors which are then forwarded to qemu. Signed-off-by: Peter Krempa --- include/libvirt/libvirt-qemu.h | 8 +++ src/driver-hypervisor.h | 10 src/libvirt-qemu.c | 89

[PATCH v2 1/4] virnetmessage: Introduce virNetMessageClearFDs

2022-02-21 Thread Peter Krempa
The helper splits out the clearing of the FDs transacted inside a virNetMessage. APIs transacting FDs both from and to the client at the same time will need to clear the FDs stored in virNetMessage as the structure is re-used for the reply and without clearing the list of FDs we'd return the FDs

[PATCH v2 0/4] qemu: Introduce 'virDomainQemuMonitorCommandWithFiles'

2022-02-21 Thread Peter Krempa
I was doing some tests with 'add-fd' and 'getfd' and made this to help me. v2: - add API support for passing FDs back, but for now we don't have use for it Peter Krempa (4): virnetmessage: Introduce virNetMessageClearFDs lib: Introduce 'virDomainQemuMonitorCommandWithFiles'