Re: [PATCH v1 06/12] target/riscv: Support start kernel directly by KVM

2021-12-02 Thread Anup Patel
On Sat, Nov 20, 2021 at 1:17 PM Yifei Jiang wrote: > > Get kernel and fdt start address in virt.c, and pass them to KVM > when cpu reset. In addition, add kvm_riscv.h to place riscv specific > interface. > > Signed-off-by: Yifei Jiang > Signed-off-by: Mingwang Li > Reviewed-by: Alistair Francis

Re: [PATCH v1 05/12] target/riscv: Implement kvm_arch_put_registers

2021-12-02 Thread Anup Patel
On Sat, Nov 20, 2021 at 1:17 PM Yifei Jiang wrote: > > Put GPR CSR and FP registers to kvm by KVM_SET_ONE_REG ioctl > > Signed-off-by: Yifei Jiang > Signed-off-by: Mingwang Li > Reviewed-by: Alistair Francis > --- > target/riscv/kvm.c | 141 - > 1

Re: [PATCH v1 04/12] target/riscv: Implement kvm_arch_get_registers

2021-12-02 Thread Anup Patel
On Sat, Nov 20, 2021 at 1:17 PM Yifei Jiang wrote: > > Get GPR CSR and FP registers from kvm by KVM_GET_ONE_REG ioctl. > > Signed-off-by: Yifei Jiang > Signed-off-by: Mingwang Li > Reviewed-by: Alistair Francis > --- > target/riscv/kvm.c | 150 - >

Re: [PATCH v1 02/12] target/riscv: Add target/riscv/kvm.c to place the public kvm interface

2021-12-02 Thread Anup Patel
On Sat, Nov 20, 2021 at 1:17 PM Yifei Jiang wrote: > > Add target/riscv/kvm.c to place kvm_arch_* function needed by > kvm/kvm-all.c. Meanwhile, add kvm support in meson.build file. > > Signed-off-by: Yifei Jiang > Signed-off-by: Mingwang Li > Reviewed-by: Alistair Francis Looks good to me.

Re: [PATCH v1 01/12] update-linux-headers: Add asm-riscv/kvm.h

2021-12-02 Thread Anup Patel
On Sat, Nov 20, 2021 at 1:17 PM Yifei Jiang wrote: > > Add asm-riscv/kvm.h for RISC-V KVM, and update linux/kvm.h > > Signed-off-by: Yifei Jiang > Signed-off-by: Mingwang Li Looks good to me. Reviewed-by: Anup Patel Regards, Anup > --- > linux-headers/asm-riscv/kvm.h | 128

[libvirt PATCH v2 11/17] qemu, hypervisor: refactor some cgroup mgmt methods

2021-12-02 Thread Praveen K Paladugu
Refactor some cgroup management methods from qemu into hypervisor. These methods will be shared by ch driver for cgroup management. Signed-off-by: Praveen K Paladugu --- src/hypervisor/domain_cgroup.c | 426 - src/hypervisor/domain_cgroup.h | 52

[libvirt PATCH v2 17/17] ch_driver: emulator threadinfo & pinning callbacks

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Praveen K Paladugu --- src/ch/ch_driver.c | 154 + 1 file changed, 154 insertions(+) diff --git a/src/ch/ch_driver.c b/src/ch/ch_driver.c index 8c14829d2a..100c54163e 100644 --- a/src/ch/ch_driver.c +++ b/src/ch/ch_driver.c @@ -1309,6

[libvirt PATCH v2 04/17] ch_domain: add virCHDomainGetMonitor helper method

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_domain.c | 6 ++ src/ch/ch_domain.h | 5 + 2 files changed, 11 insertions(+) diff --git a/src/ch/ch_domain.c b/src/ch/ch_domain.c index 44f7d26ca4..7bfe950822 100644 ---

[libvirt PATCH v2 16/17] ch_process: Setup emulator and iothread settings

2021-12-02 Thread Praveen K Paladugu
using virCHProcessSetupPid Signed-off-by: Praveen K Paladugu --- src/ch/ch_monitor.c | 60 ++ src/ch/ch_monitor.h | 2 ++ src/ch/ch_process.c | 78 +++-- 3 files changed, 138 insertions(+), 2 deletions(-) diff --git

[libvirt PATCH v2 06/17] ch_driver: fix indentation in ch_driver

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Praveen K Paladugu --- src/ch/ch_driver.c | 241 +++-- 1 file changed, 121 insertions(+), 120 deletions(-) diff --git a/src/ch/ch_driver.c b/src/ch/ch_driver.c index 464bcef907..75c6a15dd6 100644 --- a/src/ch/ch_driver.c +++

[libvirt PATCH v2 01/17] util: fix indentation in virprocess.c

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Praveen K Paladugu --- src/util/virprocess.c | 501 +- 1 file changed, 249 insertions(+), 252 deletions(-) diff --git a/src/util/virprocess.c b/src/util/virprocess.c index 7b0ad9c97b..8288e71f67 100644 --- a/src/util/virprocess.c +++

[libvirt PATCH v2 12/17] ch: methods for cgroup mgmt in ch driver

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_conf.c| 2 + src/ch/ch_conf.h| 4 +- src/ch/ch_domain.c | 34 + src/ch/ch_domain.h | 3 +- src/ch/ch_monitor.c | 96 ++ src/ch/ch_monitor.h | 54 +++-

[libvirt PATCH v2 10/17] ch_monitor: Get nicindexes in prep for cgroup mgmt

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_conf.h| 2 ++ src/ch/ch_domain.c | 27 +- src/ch/ch_domain.h | 4 +-- src/ch/ch_driver.c | 1 + src/ch/ch_monitor.c | 86 +

[libvirt PATCH v2 00/17] cgroup and thread management in ch driver

2021-12-02 Thread Praveen K Paladugu
I addressed all the open comments on the v1 patch set. In places where indentaion was hard to manage, I created explicit commits to apply correct indentation on files. Compared to v1, this version applies 2 code refactors: 1) some cgroup methods in src/qemu/qemu_cgroup.c were moved to

[libvirt PATCH v2 13/17] ch_driver, ch_domain: vcpupin callback in ch driver

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_domain.c | 30 + src/ch/ch_domain.h | 1 + src/ch/ch_driver.c | 151 + 3 files changed, 182 insertions(+) diff --git a/src/ch/ch_domain.c

[libvirt PATCH v2 07/17] ch_driver, ch_domain: vcpu info getter callbacks

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_domain.c | 25 + src/ch/ch_domain.h | 4 ++ src/ch/ch_driver.c | 137 + 3 files changed, 166 insertions(+) diff --git a/src/ch/ch_domain.c b/src/ch/ch_domain.c

[libvirt PATCH v2 14/17] ch_driver: enable typed param string for numatune

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Enable support of VIR_DRV_FEATURE_TYPED_PARAM_STRING to enable numatune Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_driver.c | 31 +++ 1 file changed, 31 insertions(+) diff --git a/src/ch/ch_driver.c

[libvirt PATCH v2 15/17] ch_driver: add numatune callbacks for CH driver

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_driver.c | 316 ++--- 1 file changed, 297 insertions(+), 19 deletions(-) diff --git a/src/ch/ch_driver.c b/src/ch/ch_driver.c index

[libvirt PATCH v2 08/17] ch_driver: domainGetVcpuPinInfo and nodeGetCPUMap

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Add domainGetVcpuPinInfo and nodeGetCPUMap callbacks to ch driver Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_domain.h | 12 +-- src/ch/ch_driver.c | 54 +- 2 files changed, 63

[libvirt PATCH v2 05/17] ch_domain: add methods to manage private vcpu data

2021-12-02 Thread Praveen K Paladugu
From: Vineeth Pillai Signed-off-by: Vineeth Pillai Signed-off-by: Praveen K Paladugu --- src/ch/ch_domain.c | 50 +- src/ch/ch_domain.h | 11 ++ 2 files changed, 56 insertions(+), 5 deletions(-) diff --git a/src/ch/ch_domain.c

[libvirt PATCH v2 02/17] util: Helper functions to get process info

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Praveen K Paladugu --- src/libvirt_private.syms | 2 + src/qemu/qemu_driver.c | 116 ++- src/util/virprocess.c| 108 src/util/virprocess.h| 5 ++ 4 files changed, 120 insertions(+), 111

[libvirt PATCH v2 03/17] ch_domain: fix indentation in ch_domain

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Praveen K Paladugu --- src/ch/ch_domain.c | 130 ++--- 1 file changed, 64 insertions(+), 66 deletions(-) diff --git a/src/ch/ch_domain.c b/src/ch/ch_domain.c index dd4de9e1ea..44f7d26ca4 100644 --- a/src/ch/ch_domain.c +++

[libvirt PATCH v2 09/17] ch_monitor: fix indentation in ch_monitor.c

2021-12-02 Thread Praveen K Paladugu
Signed-off-by: Praveen K Paladugu --- src/ch/ch_monitor.c | 301 +++- 1 file changed, 161 insertions(+), 140 deletions(-) diff --git a/src/ch/ch_monitor.c b/src/ch/ch_monitor.c index 12c10da874..68fa5b30aa 100644 --- a/src/ch/ch_monitor.c +++

Re: [PATCH] Fix reboot command for LXC containers

2021-12-02 Thread Joachim Falk
Hi Michal, Am 02.12.21 um 16:02 schrieb Michal Prívozník: > On 12/1/21 22:38, Joachim Falk wrote: >> The virNetDaemonQuit(dmn) command in virLXCControllerSignalChildIO triggers >> an >> early close of all clients of lxc_controller. Here, libvirtd itself is a >> client >> of this controller, and

Re: Release of libvirt-7.10.0

2021-12-02 Thread Olaf Hering
Am Wed, 1 Dec 2021 10:59:18 +0100 (CET) schrieb Jiri Denemark : > 7.10.0 release of both libvirt and libvirt-python Will there be a v7.10.0 tag in libvirt-perl.git? Olaf pgpbUGVZy3_YS.pgp Description: Digitale Signatur von OpenPGP

[PATCH] Fix reboot command for LXC containers

2021-12-02 Thread joachim . falk
From: Joachim Falk The virNetDaemonQuit(dmn) command in virLXCControllerSignalChildIO triggers an early close of all clients of lxc_controller. Here, libvirtd itself is a client of this controller, and the client connection is used to notify libvirtd if a reboot of the container is required.

Re: [libvirt PATCH 0/5] Add bus-lock-ratelimit

2021-12-02 Thread Daniel P . Berrangé
On Thu, Dec 02, 2021 at 06:01:03PM +0100, Tim Wiederhake wrote: > This was introduced recently in QEMU, see > https://bugzilla.redhat.com/show_bug.cgi?id=1982165: > > Bus locks disrupts overall performance since it blocks all other cores > (which must wait for the bus lock to be released

Re: [libvirt PATCH 00/14] qemu snapshot revert cleanup and refactor

2021-12-02 Thread Ján Tomko
On a Thursday in 2021, Pavel Hrdina wrote: Pavel Hrdina (14): qemu_snapshot: revert: fix incorrect jump to cleanup qemu_snapshot: revert: drop unused variable qemu_snapshot: revert: use g_autoptr qemu_snapshot: revert: jump to endjob instead of calling qemuProcessEndJob qemu_snapshot:

[libvirt PATCH 4/5] tests: Add tests for bus-lock-ratelimit

2021-12-02 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- tests/qemuxml2argvdata/kvm-features.args | 2 +- tests/qemuxml2argvdata/kvm-features.xml | 1 + tests/qemuxml2xmloutdata/kvm-features.xml | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/qemuxml2argvdata/kvm-features.args

[libvirt PATCH 0/5] Add bus-lock-ratelimit

2021-12-02 Thread Tim Wiederhake
This was introduced recently in QEMU, see https://bugzilla.redhat.com/show_bug.cgi?id=1982165: Bus locks disrupts overall performance since it blocks all other cores (which must wait for the bus lock to be released before their memory operations). For VMM, it can detect every bus lock

[libvirt PATCH 5/5] doc: Document new bus-lock-ratelimit option

2021-12-02 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- docs/formatdomain.rst | 4 1 file changed, 4 insertions(+) diff --git a/docs/formatdomain.rst b/docs/formatdomain.rst index eb8c973cf1..5b38564894 100644 --- a/docs/formatdomain.rst +++ b/docs/formatdomain.rst @@ -1864,6 +1864,7 @@ Hypervisors may allow

[libvirt PATCH 3/5] doc: schema: Add bus-lock-ratelimit to domain schema

2021-12-02 Thread Tim Wiederhake
Value is VMM exits per second. Signed-off-by: Tim Wiederhake --- docs/schemas/domaincommon.rng | 7 +++ 1 file changed, 7 insertions(+) diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index f01b7a6470..e3461ab792 100644 --- a/docs/schemas/domaincommon.rng +++

[libvirt PATCH 2/5] qemu: Add bus-lock-ratelimit

2021-12-02 Thread Tim Wiederhake
Pass bus-lock-ratelimit to qemu. Signed-off-by: Tim Wiederhake --- src/qemu/qemu_command.c | 4 1 file changed, 4 insertions(+) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index c47998aabd..dee803511b 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@

[libvirt PATCH 1/5] conf: Add bus-lock-ratelimit

2021-12-02 Thread Tim Wiederhake
QEMU recently introduced a way to limit the rate of VM bus locks. Add libvirt support. Signed-off-by: Tim Wiederhake --- src/conf/domain_conf.c | 34 ++ src/conf/domain_conf.h | 2 ++ src/qemu/qemu_validate.c | 1 + 3 files changed, 37 insertions(+) diff

Re: [libvirt PATCH 01/14] qemu_snapshot: revert: fix incorrect jump to cleanup

2021-12-02 Thread Ján Tomko
On a Thursday in 2021, Pavel Hrdina wrote: Signed-off-by: Pavel Hrdina Fixes: 6a6f6b91e0e76480ea961f83135efcb4faf3284a --- src/qemu/qemu_snapshot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

[PATCH 3/3] lib: Drop some needles labels

2021-12-02 Thread Michal Privoznik
After previous cleanups some labels became needles because they contain just a return statement. There's no point in having such labels. Signed-off-by: Michal Privoznik --- src/bhyve/bhyve_parse_command.c | 15 ++ src/conf/domain_conf.c | 4 +---

[PATCH 1/3] virdomainobjlist: Use g_autofree

2021-12-02 Thread Michal Privoznik
Instead of calling VIR_FREE() explicitly, we can annotate variables with g_autofree. Signed-off-by: Michal Privoznik --- src/conf/virdomainobjlist.c | 14 -- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/src/conf/virdomainobjlist.c b/src/conf/virdomainobjlist.c

[PATCH 0/3] lib: Use g_autoptr() for virDomainDef

2021-12-02 Thread Michal Privoznik
*** BLURB HERE *** Michal Prívozník (3): virdomainobjlist: Use g_autofree lib: Use g_autoptr() for virDomainDef lib: Drop some needles labels src/bhyve/bhyve_driver.c| 15 +++- src/bhyve/bhyve_parse_command.c | 23 +--- src/ch/ch_driver.c | 6 ++--

[PATCH 2/3] lib: Use g_autoptr() for virDomainDef

2021-12-02 Thread Michal Privoznik
Instead of calling virDomainDefFree() explicitly, we can annotate variables with g_autoptr(). Signed-off-by: Michal Privoznik --- src/bhyve/bhyve_driver.c| 15 + src/bhyve/bhyve_parse_command.c | 8 ++- src/ch/ch_driver.c | 6 ++ src/conf/domain_conf.c

Re: [libvirt PATCH] qemu: Enable unprivileged userfaultfd for post-copy migration

2021-12-02 Thread Peter Krempa
On Thu, Dec 02, 2021 at 16:56:49 +0100, Jiri Denemark wrote: > Userfaultfd is by default allowed only for privileged processes. Since > libvirt runs QEMU unprivileged, we need to enable unprivileged access to > userfaultfd before starting post-copy migration. > > Rather than providing a static

Re: [libvirt PATCH] qemu: Enable unprivileged userfaultfd for post-copy migration

2021-12-02 Thread Michal Prívozník
On 12/2/21 16:56, Jiri Denemark wrote: > Userfaultfd is by default allowed only for privileged processes. Since > libvirt runs QEMU unprivileged, we need to enable unprivileged access to > userfaultfd before starting post-copy migration. > > Rather than providing a static sysctl configuration

[libvirt PATCH] qemu: Enable unprivileged userfaultfd for post-copy migration

2021-12-02 Thread Jiri Denemark
Userfaultfd is by default allowed only for privileged processes. Since libvirt runs QEMU unprivileged, we need to enable unprivileged access to userfaultfd before starting post-copy migration. Rather than providing a static sysctl configuration file, we set the sysctl knob in runtime once

Re: [PATCH 0/3] qemu: Simplify qemuDomainGetStats() related code

2021-12-02 Thread Ján Tomko
On a Thursday in 2021, Michal Privoznik wrote: *** BLURB HERE *** Michal Prívozník (3): qemu: Drop comma after QEMU_CAPS_LAST in queryDirtyRateRequired[] qemu: prefer .requiredCaps for VIR_DOMAIN_STATS_IOTHREAD qemuConnectGetAllDomainStats: Simplify qemuDomainGetStats() error handling

Re: [PATCH] Fix reboot command for LXC containers

2021-12-02 Thread Michal Prívozník
On 12/1/21 22:38, Joachim Falk wrote: > The virNetDaemonQuit(dmn) command in virLXCControllerSignalChildIO triggers an > early close of all clients of lxc_controller. Here, libvirtd itself is a > client > of this controller, and the client connection is used to notify libvirtd if a > reboot of

[libvirt PATCH v2 09/15] qemu: add audio type 'dbus'

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- src/qemu/qemu_command.c | 12 +-- src/qemu/qemu_validate.c | 30 - .../qemuxml2argvdata/graphics-dbus-audio.args | 33 +++ tests/qemuxml2argvtest.c

[libvirt PATCH v2 08/15] conf: add support

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- docs/schemas/domaincommon.rng | 29 src/bhyve/bhyve_command.c | 1 + src/conf/domain_conf.c| 34 +++--- src/conf/domain_conf.h|

[libvirt PATCH v2 10/15] conf: add dbus

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- docs/schemas/domaincommon.rng | 8 + src/conf/domain_conf.c| 13 ++- src/conf/domain_conf.h| 1 + .../graphics-dbus-clipboard.xml | 35

[libvirt PATCH v2 15/15] docs: document type dbus

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- docs/formatdomain.rst | 43 ++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/docs/formatdomain.rst b/docs/formatdomain.rst index eb8c973cf1fc..ac298fbafa7f 100644 ---

[libvirt PATCH v2 14/15] qemu: add usbredir type 'dbus'

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau The USB device redirection works in a similar way as Spice. The underlying 'dbus' channel is set to "org.qemu.usbredir" by default for the client to identify the channel purpose (as specified in -display dbus documentation). Signed-off-by: Marc-André Lureau ---

[libvirt PATCH v2 12/15] conf: add

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Like a Spice port, a dbus serial must specify an associated channel name. Signed-off-by: Marc-André Lureau --- docs/schemas/domaincommon.rng | 1 + src/conf/domain_conf.c| 26 +++ src/conf/domain_conf.h

[libvirt PATCH v2 13/15] qemu: add -chardev dbus support

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- src/qemu/qemu_command.c | 8 + src/qemu/qemu_monitor_json.c | 9 ++ .../graphics-dbus-chardev.args| 32 +++ tests/qemuxml2argvtest.c

[libvirt PATCH v2 11/15] qemu: add dbus clipboard sharing

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau This feature requires to setup a "-chardev qemu-vdagent,clipboard=on". "qemu-vdagent" is not a typical chardev that you can connect to another end, so it doesn't map to a or . Set it up along with "-display dbus" code instead. Signed-off-by: Marc-André Lureau ---

[libvirt PATCH v2 07/15] virsh: report the D-Bus bus URI for domdisplay

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau This implementation reports only Unix bus address using the URI format proposed in https://gitlab.freedesktop.org/dbus/dbus/-/issues/348. We prefer a URI form over the D-Bus address form, since all other display protocols use a URI, allowing to distinguish between

[libvirt PATCH v2 06/15] virsh: refactor/split cmdDomDisplay()

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau The function is large and quite complex. Move the inner loop for each scheme in a separate function cmdDomDisplayScheme(). Signed-off-by: Marc-André Lureau --- tools/virsh-domain.c | 341 +-- 1 file changed, 169 insertions(+),

[libvirt PATCH v2 03/15] conf: add

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- docs/schemas/basictypes.rng | 7 ++ docs/schemas/domaincommon.rng | 33 src/conf/domain_conf.c| 78 ++- src/conf/domain_conf.h

[libvirt PATCH v2 05/15] qemu: add -display dbus support

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau By default, libvirt will start a private bus and tell QEMU to connect to it. Instead, a D-Bus "address" to connect to can be specified, or the p2p mode enabled. D-Bus display works best with GL & a rendernode, which can be specified with child element. Signed-off-by:

[libvirt PATCH v2 02/15] qemu: add -display dbus capability check (to update to 6.3)

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- src/qemu/qemu_capabilities.c | 2 ++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_6.2.0.x86_64.replies | 10 +-

[libvirt PATCH v2 04/15] qemu: start the D-Bus daemon for the display

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Start the daemon if necessary (it is already stopped in qemuProcessStop) Signed-off-by: Marc-André Lureau --- src/qemu/qemu_extdevice.c | 13 + 1 file changed, 13 insertions(+) diff --git a/src/qemu/qemu_extdevice.c b/src/qemu/qemu_extdevice.c index

[libvirt PATCH v2 01/15] qemu: add chardev-vdagent capability check

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- src/qemu/qemu_capabilities.c | 2 ++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_6.1.0.x86_64.xml | 1 + tests/qemucapabilitiesdata/caps_6.2.0.aarch64.xml | 1 +

[libvirt PATCH v2 00/15] WIP/RFC: add QEMU "-display dbus" support

2021-12-02 Thread marcandre . lureau
From: Marc-André Lureau Hi, This series implements supports for the upcoming QEMU "-display dbus" support. Development is still in progress, but I hope to land the QEMU support early in 6.3 (last version posted: https://patchew.org/QEMU/20211009210838.2219430-1-marcandre.lur...@redhat.com/).

[PATCH 0/3] qemu: Simplify qemuDomainGetStats() related code

2021-12-02 Thread Michal Privoznik
*** BLURB HERE *** Michal Prívozník (3): qemu: Drop comma after QEMU_CAPS_LAST in queryDirtyRateRequired[] qemu: prefer .requiredCaps for VIR_DOMAIN_STATS_IOTHREAD qemuConnectGetAllDomainStats: Simplify qemuDomainGetStats() error handling src/qemu/qemu_driver.c | 36

[PATCH 2/3] qemu: prefer .requiredCaps for VIR_DOMAIN_STATS_IOTHREAD

2021-12-02 Thread Michal Privoznik
Since f29d7c3e698 we have an option for checking capabilities required for given type of statistics upfront, instead of the callback. Switch qemuDomainGetStatsIOThread() callback to the new style. This will now error out properly if user requests IOTHREAD stats forcibly (via

[PATCH 1/3] qemu: Drop comma after QEMU_CAPS_LAST in queryDirtyRateRequired[]

2021-12-02 Thread Michal Privoznik
The idea of queryDirtyRateRequired[] is that it lists QEMU capabilities required for given domstats record (VIR_DOMAIN_STATS_DIRTYRATE in this particular case) and QEMU_CAPS_LAST is used as a sentinel. Therefore, there can never be anything after it. Drop the comma to make it more obvious.

[PATCH 3/3] qemuConnectGetAllDomainStats: Simplify qemuDomainGetStats() error handling

2021-12-02 Thread Michal Privoznik
In qemuConnectGetAllDomainStats() there a loop that iterates over all domains that stats are to be fetched for. Within this loop the qemuDomainGetStats() is called which is responsible for fetching stats for an individual domain. Now, the code that handles successful and failure cases is almost

Re: [PATCH v2] virnetdevveth: Do report error if creating veth fails

2021-12-02 Thread Martin Kletzander
On Thu, Dec 02, 2021 at 02:41:47PM +0100, Michal Privoznik wrote: For some weird reason we are ignoring errors when creating veth pair that netlink reports. This affects the LXC driver which creates interfaces for container in virLXCProcessSetupInterfaces(). If creating a veth pair fails, no

Re: [libvirt PATCH 1/9] qemu: start the D-Bus daemon as needed

2021-12-02 Thread Marc-André Lureau
On Mon, Nov 29, 2021 at 9:20 PM Michal Prívozník wrote: > > On 11/5/21 11:51, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > The daemon is started on daemon in external devices and hotplug code. > > Add a mechanism to start it before qemu, if qemu itself needs it. (it is

Re: [libvirt PATCH 4/9] qemu: add -display dbus support

2021-12-02 Thread Marc-André Lureau
Hi On Mon, Nov 29, 2021 at 9:20 PM Michal Prívozník wrote: > > On 11/5/21 11:51, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Without any extra option, libvirt will start and tell QEMU to connect to > > the private VM bus. > > > > Instead, a D-Bus "address" to connect

[PATCH v2] virnetdevveth: Do report error if creating veth fails

2021-12-02 Thread Michal Privoznik
For some weird reason we are ignoring errors when creating veth pair that netlink reports. This affects the LXC driver which creates interfaces for container in virLXCProcessSetupInterfaces(). If creating a veth pair fails, no error is reported and the control jumps onto cleanup label where some

[libvirt PATCH 13/14] qemu_snapshot: revert: rename qemuSnapshotRevertInactive

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 4f0e484ab5..6b300d808a 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -2126,9

[libvirt PATCH 01/14] qemu_snapshot: revert: fix incorrect jump to cleanup

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index edf5511e42..64b5838db8 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -2087,7 +2087,7 @@

[libvirt PATCH 11/14] qemu_snapshot: revert: save metadata within qemu process job

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 8ad441e41a..5c974280af 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -2276,14

[libvirt PATCH 14/14] qemu_snapshot: revert: move inactive snapshot to separate function

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 148 ++- 1 file changed, 83 insertions(+), 65 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 6b300d808a..1a32b15f51 100644 --- a/src/qemu/qemu_snapshot.c +++

[libvirt PATCH 10/14] qemu_snapshot: revert: move saving metadata to separate function

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 58 +--- 1 file changed, 36 insertions(+), 22 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 1d4af221e2..8ad441e41a 100644 --- a/src/qemu/qemu_snapshot.c +++

[libvirt PATCH 09/14] qemu_snapshot: revert: refactor cleanup section

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 20 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 950b1a65ff..1d4af221e2 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c

[libvirt PATCH 12/14] qemu_snapshot: revert: move active snapshot revert to separate function

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 171 ++- 1 file changed, 98 insertions(+), 73 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 5c974280af..4f0e484ab5 100644 --- a/src/qemu/qemu_snapshot.c +++

[libvirt PATCH 08/14] qemu_snapshot: revert: emit event right after they are created

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 589daaa73e..950b1a65ff 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -2131,6

[libvirt PATCH 05/14] qemu_snapshot: revert: remove cleanup label

2021-12-02 Thread Pavel Hrdina
Now the cleanup label is not necessary so we can drop it. Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 8191733a6d..beeb012431 100644 ---

[libvirt PATCH 07/14] qemu_snapshot: revert: move config prepare code to separate function

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 95 +--- 1 file changed, 59 insertions(+), 36 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index cc219f8b64..589daaa73e 100644 --- a/src/qemu/qemu_snapshot.c +++

[libvirt PATCH 06/14] qemu_snapshot: revert: move validation to separate function

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 78 ++-- 1 file changed, 44 insertions(+), 34 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index beeb012431..cc219f8b64 100644 --- a/src/qemu/qemu_snapshot.c +++

[libvirt PATCH 04/14] qemu_snapshot: revert: jump to endjob instead of calling qemuProcessEndJob

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 5ac1c99a68..8191733a6d 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -2149,8

[libvirt PATCH 02/14] qemu_snapshot: revert: drop unused variable

2021-12-02 Thread Pavel Hrdina
Commit dropped unused code but missed one variable. Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 64b5838db8..413b31bae5 100644 --- a/src/qemu/qemu_snapshot.c +++

[libvirt PATCH 03/14] qemu_snapshot: revert: use g_autoptr

2021-12-02 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- src/qemu/qemu_snapshot.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 413b31bae5..5ac1c99a68 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -1940,8

[libvirt PATCH 00/14] qemu snapshot revert cleanup and refactor

2021-12-02 Thread Pavel Hrdina
Pavel Hrdina (14): qemu_snapshot: revert: fix incorrect jump to cleanup qemu_snapshot: revert: drop unused variable qemu_snapshot: revert: use g_autoptr qemu_snapshot: revert: jump to endjob instead of calling qemuProcessEndJob qemu_snapshot: revert: remove cleanup label

Re: [PATCH] virnetdevveth: Do report error if creating veth fails

2021-12-02 Thread Martin Kletzander
On Thu, Dec 02, 2021 at 01:10:20PM +0100, Michal Privoznik wrote: For some weird reason we are ignoring errors when creating veth pair that netlink reports. This affects the LXC driver which creates interfaces for container in virLXCProcessSetupInterfaces(). If creating a veth pair fails, no

[PATCH] virnetdevveth: Do report error if creating veth fails

2021-12-02 Thread Michal Privoznik
For some weird reason we are ignoring errors when creating veth pair that netlink reports. This affects the LXC driver which creates interfaces for container in virLXCProcessSetupInterfaces(). If creating a veth pair fails, no error is reported and the control jumps onto cleanup label where some

[libvirt PATCH v7 3/3] Ignore EPERM on implicit clearing of VF VLAN ID

2021-12-02 Thread Dmitrii Shcherbakov
SmartNIC DPUs may not expose some privileged eswitch operations to the hypervisor hosts. For example, this happens with Bluefield devices running in the ECPF (default) mode for security reasons. While VF MAC address programming is possible via an RTM_SETLINK operation, trying to set a VLAN ID in

[libvirt PATCH v7 0/3] Ignore EPERM on implicit clearing of VF VLAN ID

2021-12-02 Thread Dmitrii Shcherbakov
SmartNIC DPUs may not expose some privileged eswitch operations to the hypervisor hosts. For example, this happens with Bluefield devices running in the ECPF (default) mode [1] for security reasons. While VF MAC address programming is possible via an RTM_SETLINK operation, trying to set a VLAN ID

[libvirt PATCH v7 1/3] Set VF MAC and VLAN ID in two different operations

2021-12-02 Thread Dmitrii Shcherbakov
This has a benefit of being able to handle error codes for those operations separately which is useful when drivers allow setting a MAC address but do not allow setting a VLAN (which is the case with some SmartNIC DPUs). Signed-off-by: Dmitrii Shcherbakov --- src/libvirt_private.syms | 7 ++

[libvirt PATCH v7 2/3] Allow VF vlanid to be passed as a pointer

2021-12-02 Thread Dmitrii Shcherbakov
There should be a way to show no intent in programming a VLAN at all (including clearing it). This allows handling error conditions differently when VLAN clearing is explicit (vlan id == 0) vs implicit (vlanid == NULL - try to clear it if possible). Signed-off-by: Dmitrii Shcherbakov ---

[PATCH v3 3/4] qemu: Generate command line for tb-cache feature

2021-12-02 Thread Michal Privoznik
Generating command line is pretty easy - just put tb-size=XXX onto -accel tcg part. Note, that QEMU expects the size in MiB. Resolves: https://gitlab.com/libvirt/libvirt/-/issues/229 Signed-off-by: Michal Privoznik Tested-by: Kashyap Chamarthy --- src/qemu/qemu_command.c

[PATCH v3 4/4] NEWS: Document TCG features

2021-12-02 Thread Michal Privoznik
Signed-off-by: Michal Privoznik --- NEWS.rst | 5 + 1 file changed, 5 insertions(+) diff --git a/NEWS.rst b/NEWS.rst index 4d690ff64b..4c56377cac 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -17,6 +17,11 @@ v8.0.0 (unreleased) * **New features** + * Introduce TCG domain features + +

[PATCH v3 2/4] qemu: Validate TCG feature is enabled only for TCG domains

2021-12-02 Thread Michal Privoznik
After previous commit it's possible for domains to fine tune TCG features (well, just one - tb-cache). Check that domain has TCG enabled, otherwise the feature makes no sense. Signed-off-by: Michal Privoznik --- docs/formatdomain.rst| 2 +- src/qemu/qemu_validate.c | 16 2

[PATCH v3 1/4] conf: Introduce TCG domain features

2021-12-02 Thread Michal Privoznik
It may come handy to be able to tweak TCG options, in this specific case the size of translation block cache size (tb-size). Since we can expect more knobs to tweak let's put them under common element, like this: 128 Signed-off-by: Michal Privoznik

[PATCH v3 0/4] Introduce TCG domain features

2021-12-02 Thread Michal Privoznik
v3 of: https://listman.redhat.com/archives/libvir-list/2021-November/msg00194.html Note, patches 1/4 and 2/4 from v2 were pushed already. diff to v2: - Split feature validation into a separate patch - Validate that the size is a multiple of MiB, because that's QEMU's granularity - Remembered