Re: [PATCH v4 2/2] Added parameter to take screenshot with screendump as PNG

2022-04-05 Thread Markus Armbruster
Kshitij Suri writes: > On 01/04/22 4:50 pm, Markus Armbruster wrote: >> Dave, please have a look at the HMP compatibility issue in >> hmp-command.hx below. >> >> Kshitij Suri writes: >> >>> Currently screendump only supports PPM format, which is un-compressed and >>> not >>> standard. >> If "st

Re: [PATCH] vdpa: Add missing tracing to batch mapping functions

2022-04-05 Thread Stefano Garzarella
On Tue, Apr 05, 2022 at 08:36:28AM +0200, Eugenio Pérez wrote: These functions were not traced properly. Signed-off-by: Eugenio Pérez --- hw/virtio/vhost-vdpa.c | 2 ++ hw/virtio/trace-events | 2 ++ 2 files changed, 4 insertions(+) Reviewed-by: Stefano Garzarella diff --git a/hw/virtio/vho

Re: [PATCH-for-7.0 v2] qga/vss-win32: fix compilation with clang++

2022-04-05 Thread Konstantin Kostiuk
Reviewed-by: Konstantin Kostiuk On Wed, Mar 16, 2022 at 3:58 PM Helge Konetzka wrote: > This fixes: > > qga/vss-win32/install.cpp:49:24: error: cannot initialize a variable of > type 'char *' with an rvalue of type 'const char *' > char *msg = NULL, *nul = strchr(text, '('); >

Re: [PATCH 0/1] xlnx-bbram: hw/nvram: Fix Coverity CID 1487233

2022-04-05 Thread Peter Maydell
On Fri, 1 Apr 2022 at 20:06, Tong Ho wrote: > > This patch addresses Coverity CID 1487233 by adding the required > initialiation of a local variable of type Error *. > > Tong Ho (1): > xlnx-bbram: hw/nvram: Fix uninitialized Error * > > hw/nvram/xlnx-bbram.c | 2 +- > 1 file changed, 1 insertio

Re: [PATCH] docs/system/devices/can.rst: correct links to CTU CAN FD IP core documentation.

2022-04-05 Thread Peter Maydell
On Sat, 2 Apr 2022 at 21:47, Pavel Pisa wrote: > > Signed-off-by: Pavel Pisa > --- > docs/system/devices/can.rst | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) Applied to target-arm.next for 7.0, thanks. -- PMM

Re: [libvirt RFC] virFile: new VIR_FILE_WRAPPER_BIG_PIPE to improve performance

2022-04-05 Thread Dr. David Alan Gilbert
* Claudio Fontana (cfont...@suse.de) wrote: > On 3/28/22 10:31 AM, Daniel P. Berrangé wrote: > > On Sat, Mar 26, 2022 at 04:49:46PM +0100, Claudio Fontana wrote: > >> On 3/25/22 12:29 PM, Daniel P. Berrangé wrote: > >>> On Fri, Mar 18, 2022 at 02:34:29PM +0100, Claudio Fontana wrote: > On 3/17

Re: [PATCH v9 18/45] hw/cxl/device: Implement MMIO HDM decoding (8.2.5.12)

2022-04-05 Thread Jonathan Cameron via
On Mon, 4 Apr 2022 12:19:07 -0700 Tong Zhang wrote: > > On Apr 4, 2022, at 8:14 AM, Jonathan Cameron via > > wrote: > > > > From: Ben Widawsky > > > > A device's volatile and persistent memory are known Host Defined Memory > > (HDM) regions. The mechanism by which the device is programmed to

Re: [qemu.qmp PATCH 02/13] fork qemu.qmp from qemu.git

2022-04-05 Thread Kashyap Chamarthy
On Mon, Apr 04, 2022 at 02:56:10PM -0400, John Snow wrote: > On Mon, Apr 4, 2022 at 2:54 PM John Snow wrote: [...] > > > > .gitignore | 2 +- > > > > Makefile | 16 > > > > setup.cfg | 24 +--- > > > > setup.py | 2 +- > > > > 4 files changed, 11 inse

Re: [RFC PATCH] python: add qmp-send program to send raw qmp commands to qemu

2022-04-05 Thread Damien Hedde
On 4/4/22 22:34, John Snow wrote: On Wed, Mar 16, 2022 at 5:55 AM Damien Hedde wrote: It takes an input file containing raw qmp commands (concatenated json dicts) and send all commands one by one to a qmp server. When one command fails, it exits. As a convenience, it can also wrap the qemu

Re: [PATCH v8 04/46] hw/cxl/device: Introduce a CXL device (8.2.8)

2022-04-05 Thread Jonathan Cameron via
... > > > > > > > > > > Can we switch this to mem_size and drop the persistent comment? It is > > > > > my > > > > > understanding that HDM is independent of persistence. > > > > > > > > Discussed in the other branch of this thread. Short answer is we don't > > > > support non persistent

Re: [qemu.qmp PATCH 10/13] docs: add versioning policy to README

2022-04-05 Thread Damien Hedde
On 3/30/22 20:24, John Snow wrote: The package is in an alpha state, but there's a method to the madness. Signed-off-by: John Snow --- README.rst | 21 + 1 file changed, 21 insertions(+) diff --git a/README.rst b/README.rst index 8593259..88efe84 100644 --- a/README.r

[PULL 0/3] Misc changes for 2022-04-05

2022-04-05 Thread Paolo Bonzini
The following changes since commit 20661b75ea6093f5e59079d00a778a972d6732c5: Merge tag 'pull-ppc-20220404' of https://github.com/legoater/qemu into staging (2022-04-04 15:48:55 +0100) are available in the Git repository at: https://gitlab.com/bonzini/qemu.git tags/for-upstream for you to f

[PULL 3/3] docs/system/i386: Add measurement calculation details to amd-memory-encryption

2022-04-05 Thread Paolo Bonzini
From: Dov Murik Add a section explaining how the Guest Owner should calculate the expected guest launch measurement for SEV and SEV-ES. Also update the name and links to the SEV API Spec document. Signed-off-by: Dov Murik Suggested-by: Daniel P. Berrangé Reviewed-by: Dr. David Alan Gilbert

[PULL 1/2] xlnx-bbram: hw/nvram: Fix uninitialized Error *

2022-04-05 Thread Peter Maydell
From: Tong Ho This adds required initialization of Error * variable. Signed-off-by: Tong Ho Reviewed-by: Francisco Iglesias Signed-off-by: Peter Maydell --- hw/nvram/xlnx-bbram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/nvram/xlnx-bbram.c b/hw/nvram/xlnx-bbram.c

[PULL 0/2] target-arm queue

2022-04-05 Thread Peter Maydell
org/people/pmaydell/qemu-arm.git tags/pull-target-arm-20220405 for you to fetch changes up to 80b952bb694a90f7e530d407b01066894e64a443: docs/system/devices/can.rst: correct links to CTU CAN FD IP core documentation. (2022-04-05 09:2

[PULL 1/3] coverity: update model for latest tools

2022-04-05 Thread Paolo Bonzini
Coverity is now rejecting incomplete types in the modeling file. Just use a random number (in the neighborhood of the actual one) for the size of a GIOChannel. Signed-off-by: Paolo Bonzini --- scripts/coverity-scan/model.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scr

[PULL 2/3] qga/vss-win32: fix compilation with clang++

2022-04-05 Thread Paolo Bonzini
From: Helge Konetzka This fixes: qga/vss-win32/install.cpp:49:24: error: cannot initialize a variable of type 'char *' with an rvalue of type 'const char *' char *msg = NULL, *nul = strchr(text, '('); ^ ~ Signed-off-by: Helge Konetzka Reviewed-by:

Re: [libvirt RFC] virFile: new VIR_FILE_WRAPPER_BIG_PIPE to improve performance

2022-04-05 Thread Claudio Fontana
On 4/5/22 10:35 AM, Dr. David Alan Gilbert wrote: > * Claudio Fontana (cfont...@suse.de) wrote: >> On 3/28/22 10:31 AM, Daniel P. Berrangé wrote: >>> On Sat, Mar 26, 2022 at 04:49:46PM +0100, Claudio Fontana wrote: On 3/25/22 12:29 PM, Daniel P. Berrangé wrote: > On Fri, Mar 18, 2022 at 02

Re: [RFC PATCH 0/5] Removal of AioContext lock, bs->parents and ->children: proof of concept

2022-04-05 Thread Stefan Hajnoczi
On Mon, Apr 04, 2022 at 11:41:04AM +0200, Paolo Bonzini wrote: > On Mon, Apr 4, 2022 at 11:25 AM Stefan Hajnoczi wrote: > > - The new API still needs to be combined with bdrv_drained_begin/end() > > to ensure in-flight requests are done. > > > > I don't think so, because in-flight requests woul

[PULL 2/2] docs/system/devices/can.rst: correct links to CTU CAN FD IP core documentation.

2022-04-05 Thread Peter Maydell
From: Pavel Pisa Signed-off-by: Pavel Pisa Reviewed-by: Francisco Iglesias Message-id: 20220402204523.32643-1-p...@cmp.felk.cvut.cz Signed-off-by: Peter Maydell --- docs/system/devices/can.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/system/devices/can.rs

Re: [RFC PATCH] python: add qmp-send program to send raw qmp commands to qemu

2022-04-05 Thread Markus Armbruster
Damien Hedde writes: > On 4/4/22 22:34, John Snow wrote: >> On Wed, Mar 16, 2022 at 5:55 AM Damien Hedde >> wrote: [...] >> I recommend putting this in qemu/util/qmp_send.py instead. >> I'm in the process of pulling out the AQMP lib and hosting it >> separately. Scripts like this I think shou

Re: [PATCH v4 10/11] tests/tcg/s390x: Tests for Vector Enhancements Facility 2

2022-04-05 Thread David Hildenbrand
On 01.04.22 17:25, Christian Borntraeger wrote: > Am 01.04.22 um 17:02 schrieb David Miller: >> vrr is almost a perfect match (it is for this, larger than imm4 would >> need to be split). >> >> .long : this would be uglier. >> use enough to be filled with nops after ? >> or use a 32b and 16b instea

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Kevin Wolf
Am 24.03.2022 um 13:57 hat Hanna Reitz geschrieben: > When the stream block job cuts out the nodes between top and base in > stream_prepare(), it does not drain the subtree manually; it fetches the > base node, and tries to insert it as the top node's backing node with > bdrv_set_backing_hd(). bdr

Re: [PATCH] hw/pvrdma: Some cosmetic fixes

2022-04-05 Thread Marcel Apfelbaum
On Sun, Apr 3, 2022 at 12:00 PM Yuval Shaia wrote: > > Signed-off-by: Yuval Shaia > --- > hw/rdma/vmw/pvrdma_main.c | 9 + > 1 file changed, 5 insertions(+), 4 deletions(-) > > diff --git a/hw/rdma/vmw/pvrdma_main.c b/hw/rdma/vmw/pvrdma_main.c > index 91206dbb8e..aae382af59 100644 > ---

Re: [PATCH v3] hw/pvrdma: Protect against buggy or malicious guest driver

2022-04-05 Thread Marcel Apfelbaum
Hi Yuval, Thank you for the changes. On Sun, Apr 3, 2022 at 11:54 AM Yuval Shaia wrote: > > Guest driver might execute HW commands when shared buffers are not yet > allocated. > This could happen on purpose (malicious guest) or because of some other > guest/host address mapping error. > We need t

[PULL 05/10] qapi: fix example of query-vnc command

2022-04-05 Thread Markus Armbruster
From: Victor Toso The return value is missing the mandatory member @websocket. Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-6-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Armbruster --- qapi/ui.json | 1 + 1 file changed, 1 insertion(+)

[PULL 01/10] qapi: fix example of netdev_add command

2022-04-05 Thread Markus Armbruster
From: Victor Toso Example output has the optional member @dnssearch as string type. It should be an array of String objects instead. Fix it. For reference, see NetdevUserOptions. Signed-off-by: Victor Toso Message-Id: <20220401110712.26911-1-victort...@redhat.com> Reviewed-by: Markus Armbruste

[PULL 06/10] qapi: fix example of query-colo-status command

2022-04-05 Thread Markus Armbruster
From: Victor Toso The example output is missing the mandatory member @last-mode in the return value. Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-7-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Armbruster --- qapi/migration.json | 2 +-

[PATCH] ui/cursor: fix integer overflow in cursor_alloc (CVE-2022-4206)

2022-04-05 Thread Mauro Matteo Cascella
Prevent potential integer overflow by limiting 'width' and 'height' to 512x512. Also change 'datasize' type to size_t. Refer to security advisory https://starlabs.sg/advisories/22-4206/ for more information. Fixes: CVE-2022-4206 Signed-off-by: Mauro Matteo Cascella --- hw/display/qxl-render.c |

[PULL 09/10] qapi: fix example of query-memdev command

2022-04-05 Thread Markus Armbruster
From: Victor Toso Example output is missing mandatory argument @share for the return JSON object. Add it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-10-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Armbruster --- qapi/machine.json | 2 ++ 1 fi

[PULL 04/10] qapi: fix example of query-spice command

2022-04-05 Thread Markus Armbruster
From: Victor Toso Example output is missing mandatory members @migrated and @mouse-mode. Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-5-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Armbruster --- qapi/ui.json | 2 ++ 1 file changed, 2 i

[PULL 00/10] QAPI patches patches for 2022-04-05

2022-04-05 Thread Markus Armbruster
I double-checked these patches affect *only* generated documentation. Safe enough for 7.0, I think. But I'm quite content to hold on to them until after the release, if that's preferred. The following changes since commit 20661b75ea6093f5e59079d00a778a972d6732c5: Merge tag 'pull-ppc-20220404'

[PULL 08/10] qapi: fix example of query-cpus-fast command

2022-04-05 Thread Markus Armbruster
From: Victor Toso Example output contains member @arch that was removed in 445a5b4087 "machine: remove 'arch' field from 'query-cpus-fast' QMP command". Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-9-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by:

[PATCH] display/qxl-render: fix race condition in qxl_cursor (CVE-2022-4207)

2022-04-05 Thread Mauro Matteo Cascella
Avoid fetching 'width' and 'height' a second time to prevent possible race condition. Refer to security advisory https://starlabs.sg/advisories/22-4207/ for more information. Fixes: CVE-2022-4207 Signed-off-by: Mauro Matteo Cascella --- hw/display/qxl-render.c | 2 +- 1 file changed, 1 insertion

Re: [PATCH v5 00/13] KVM: mm: fd-based approach for supporting KVM guest private memory

2022-04-05 Thread Quentin Perret
On Monday 04 Apr 2022 at 15:04:17 (-0700), Andy Lutomirski wrote: > > > On Mon, Apr 4, 2022, at 10:06 AM, Sean Christopherson wrote: > > On Mon, Apr 04, 2022, Quentin Perret wrote: > >> On Friday 01 Apr 2022 at 12:56:50 (-0700), Andy Lutomirski wrote: > >> FWIW, there are a couple of reasons why

[PULL 03/10] qapi: fix example of query-named-block-nodes command

2022-04-05 Thread Markus Armbruster
From: Victor Toso Example output is missing mandatory member @detect_zeroes. Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-4-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Armbruster --- qapi/block-core.json | 1 + 1 file changed, 1 insert

[PULL 02/10] qapi: fix examples: replay-break and replay-seek

2022-04-05 Thread Markus Armbruster
From: Victor Toso Both examples outputs are using @data member for the arguments. This is wrong. The expected member for the QMP is @arguments. Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-3-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Ar

Re: [PATCH] display/qxl-render: fix race condition in qxl_cursor (CVE-2022-4207)

2022-04-05 Thread Marc-André Lureau
On Tue, Apr 5, 2022 at 2:55 PM Mauro Matteo Cascella wrote: > Avoid fetching 'width' and 'height' a second time to prevent possible > race condition. Refer to security advisory > https://starlabs.sg/advisories/22-4207/ for more information. > > Fixes: CVE-2022-4207 > Signed-off-by: Mauro Matteo C

Re: [RFC PATCH 0/5] Removal of AioContext lock, bs->parents and ->children: proof of concept

2022-04-05 Thread Kevin Wolf
Am 04.04.2022 um 11:41 hat Paolo Bonzini geschrieben: > As an aside, instead of is_external, QEMU could remove/add the ioeventfd > handler in the blk->dev_ops->drained_begin and blk->dev_ops->drained_end > callbacks respectively. But that's just a code cleanup. Yes, this is the proper way to do it

[PULL 10/10] qapi: Fix calc-dirty-rate example

2022-04-05 Thread Markus Armbruster
The example shows {"command": ...}, which is wrong. Fix it to {"execute": ...}. Signed-off-by: Markus Armbruster Message-Id: <20220401082028.3583296-1-arm...@redhat.com> Reviewed-by: Victor Toso --- qapi/migration.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/mi

[PULL 07/10] qapi: fix example of trace-event-get-state command

2022-04-05 Thread Markus Armbruster
From: Victor Toso The example output is missing the mandatory member @vcpu. Fix it. Signed-off-by: Victor Toso Message-Id: <20220331190633.121077-8-victort...@redhat.com> Reviewed-by: Markus Armbruster Signed-off-by: Markus Armbruster --- qapi/trace.json | 2 +- 1 file changed, 1 insertion(+

Re: [PATCH 0/2] virtio: Add vhost-user-gpio device's support

2022-04-05 Thread Alex Bennée
Viresh Kumar writes: > Hello, > > This patchset adds vhost-user-gpio device's support in Qemu. The support for > the > same has already been added to virtio specification and Linux Kernel. > > A Rust based backend is also in progress and is tested against this patchset: > > https://github.com/

Re: [RFC PATCH 0/5] Removal of AioContext lock, bs->parents and ->children: proof of concept

2022-04-05 Thread Kevin Wolf
Am 30.03.2022 um 11:58 hat Emanuele Giuseppe Esposito geschrieben: > > > Am 30/03/2022 um 11:52 schrieb Vladimir Sementsov-Ogievskiy: > > 30.03.2022 12:09, Emanuele Giuseppe Esposito wrote: > >>> > >>> Ah seems I understand what you mean. > >>> > >>> One of my arguments is that "drain" - is not a

Re: [PATCH] ui/cursor: fix integer overflow in cursor_alloc (CVE-2022-4206)

2022-04-05 Thread Gerd Hoffmann
> > +++ b/ui/cursor.c > > @@ -46,6 +46,13 @@ static QEMUCursor *cursor_parse_xpm(const char *xpm[]) > > > > /* parse pixel data */ > > c = cursor_alloc(width, height); > > + > > +if (!c) { > > +fprintf(stderr, "%s: cursor %ux%u alloc error\n", > > +__func__, wi

Re: [PATCH] ui/cursor: fix integer overflow in cursor_alloc (CVE-2022-4206)

2022-04-05 Thread Marc-André Lureau
Hi On Tue, Apr 5, 2022 at 2:43 PM Mauro Matteo Cascella wrote: > Prevent potential integer overflow by limiting 'width' and 'height' to > 512x512. Also change 'datasize' type to size_t. Refer to security > advisory https://starlabs.sg/advisories/22-4206/ for more information. > > Fixes: CVE-2022

Re: [PATCH] display/qxl-render: fix race condition in qxl_cursor (CVE-2022-4207)

2022-04-05 Thread Gerd Hoffmann
On Tue, Apr 05, 2022 at 12:35:05PM +0200, Mauro Matteo Cascella wrote: > Avoid fetching 'width' and 'height' a second time to prevent possible > race condition. Refer to security advisory > https://starlabs.sg/advisories/22-4207/ for more information. > > Fixes: CVE-2022-4207 > Signed-off-by: Maur

[PATCH] hw/ppc/ppc405_boards: Initialize g_autofree pointer

2022-04-05 Thread Bernhard Beschow
Resolves the only compiler warning when building a full QEMU under Arch Linux: Compiling C object libqemu-ppc-softmmu.fa.p/hw_ppc_ppc405_boards.c.o In file included from /usr/include/glib-2.0/glib.h:114, from qemu/include/glib-compat.h:32, from qemu/includ

Re: [PATCH 1/2] hw/xen/xen_pt: Confine igd-passthrough-isa-bridge to XEN

2022-04-05 Thread Bernhard Beschow
Am 26. März 2022 16:58:23 UTC schrieb Bernhard Beschow : >igd-passthrough-isa-bridge is only requested in xen_pt but was >implemented in pc_piix.c. This caused xen_pt to dependend on i386/pc >which is hereby resolved. > >Signed-off-by: Bernhard Beschow >--- > hw/i386/pc_piix.c| 118 ---

Re: [PATCH v2 5/7] block/block-copy: block_copy(): add timeout_ns parameter

2022-04-05 Thread Vladimir Sementsov-Ogievskiy
04.04.2022 17:39, Hanna Reitz wrote: On 01.04.22 18:08, Vladimir Sementsov-Ogievskiy wrote: 01.04.2022 16:16, Hanna Reitz wrote: On 01.04.22 11:19, Vladimir Sementsov-Ogievskiy wrote: Add possibility to limit block_copy() call in time. To be used in the next commit. Signed-off-by: Vladimir Se

Re: [PULL 0/3] Misc changes for 2022-04-05

2022-04-05 Thread Peter Maydell
On Tue, 5 Apr 2022 at 10:25, Paolo Bonzini wrote: > > The following changes since commit 20661b75ea6093f5e59079d00a778a972d6732c5: > > Merge tag 'pull-ppc-20220404' of https://github.com/legoater/qemu into > staging (2022-04-04 15:48:55 +0100) > > are available in the Git repository at: > > h

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Hanna Reitz
On 05.04.22 12:14, Kevin Wolf wrote: Am 24.03.2022 um 13:57 hat Hanna Reitz geschrieben: When the stream block job cuts out the nodes between top and base in stream_prepare(), it does not drain the subtree manually; it fetches the base node, and tries to insert it as the top node's backing node

Re: [PATCH] ui/cursor: fix integer overflow in cursor_alloc (CVE-2022-4206)

2022-04-05 Thread Peter Maydell
On Tue, 5 Apr 2022 at 11:50, Mauro Matteo Cascella wrote: > > Prevent potential integer overflow by limiting 'width' and 'height' to > 512x512. Also change 'datasize' type to size_t. Refer to security > advisory https://starlabs.sg/advisories/22-4206/ for more information. > > Fixes: CVE-2022-4206

Re: [PATCH] hw/ppc/ppc405_boards: Initialize g_autofree pointer

2022-04-05 Thread Peter Maydell
On Tue, 5 Apr 2022 at 12:32, Bernhard Beschow wrote: > > Resolves the only compiler warning when building a full QEMU under Arch Linux: > > Compiling C object libqemu-ppc-softmmu.fa.p/hw_ppc_ppc405_boards.c.o > In file included from /usr/include/glib-2.0/glib.h:114, >from q

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Hanna Reitz
On 05.04.22 13:47, Hanna Reitz wrote: On 05.04.22 12:14, Kevin Wolf wrote: [...] At the same time they probably do too little, because what you're describing you're protecting against is not I/O, but graph modifications done by callbacks invoked in the AIO_WAIT_WHILE() when replacing the back

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Vladimir Sementsov-Ogievskiy
05.04.2022 13:14, Kevin Wolf wrote: Am 24.03.2022 um 13:57 hat Hanna Reitz geschrieben: When the stream block job cuts out the nodes between top and base in stream_prepare(), it does not drain the subtree manually; it fetches the base node, and tries to insert it as the top node's backing node w

[PATCH] [PATCH RFC v3] Implements Backend Program conventions for vhost-user-scsi

2022-04-05 Thread Sakshi Kaushik
Signed-off-by: Sakshi Kaushik --- contrib/vhost-user-scsi/vhost-user-scsi.c | 76 +++ 1 file changed, 51 insertions(+), 25 deletions(-) diff --git a/contrib/vhost-user-scsi/vhost-user-scsi.c b/contrib/vhost-user-scsi/vhost-user-scsi.c index 4f6e3e2a24..74ec44d190 100644 ---

Re: [PATCH] hw/ppc/ppc405_boards: Initialize g_autofree pointer

2022-04-05 Thread Bernhard Beschow
Am 5. April 2022 12:00:19 UTC schrieb Peter Maydell : >On Tue, 5 Apr 2022 at 12:32, Bernhard Beschow wrote: >> >> Resolves the only compiler warning when building a full QEMU under Arch >> Linux: >> >> Compiling C object libqemu-ppc-softmmu.fa.p/hw_ppc_ppc405_boards.c.o >> In file included fr

[PATCH v2] hw/ppc/ppc405_boards: Initialize g_autofree pointer

2022-04-05 Thread Bernhard Beschow
Resolves the only compiler warning when building a full QEMU under Arch Linux: Compiling C object libqemu-ppc-softmmu.fa.p/hw_ppc_ppc405_boards.c.o In file included from /usr/include/glib-2.0/glib.h:114, from qemu/include/glib-compat.h:32, from qemu/includ

Re: [PATCH v2] hw/ppc/ppc405_boards: Initialize g_autofree pointer

2022-04-05 Thread Peter Maydell
On Tue, 5 Apr 2022 at 13:40, Bernhard Beschow wrote: > > Resolves the only compiler warning when building a full QEMU under Arch Linux: > > Compiling C object libqemu-ppc-softmmu.fa.p/hw_ppc_ppc405_boards.c.o > In file included from /usr/include/glib-2.0/glib.h:114, >from q

Re: [RFC PATCH] python: add qmp-send program to send raw qmp commands to qemu

2022-04-05 Thread Damien Hedde
On 4/5/22 07:41, Markus Armbruster wrote: Daniel P. Berrangé writes: On Wed, Mar 16, 2022 at 10:54:55AM +0100, Damien Hedde wrote: It takes an input file containing raw qmp commands (concatenated json dicts) and send all commands one by one to a qmp server. When one command fails, it exits

Re: [PULL 0/2] target-arm queue

2022-04-05 Thread Peter Maydell
2-04-04 15:48:55 +0100) > > are available in the Git repository at: > > https://git.linaro.org/people/pmaydell/qemu-arm.git > tags/pull-target-arm-20220405 > > for you to fetch changes up to 80b952bb694a90f7e530d407b01066894e64a443: > > docs/system/devices/can.rst: corr

[RFC PATCH 0/1] add Valgrind hint in kvm_get_one_reg()

2022-04-05 Thread Daniel Henrique Barboza
Hi, Valgrind is not happy with how we're using KVM functions that receives a parameter via reference and write them. This results in a lot of complaints about uninitialized values when using these functions because, as default, Valgrind doesn't know that the variable is being initialized in the fu

[RFC PATCH 1/1] kvm-all.c: hint Valgrind that kvm_get_one_reg() inits memory

2022-04-05 Thread Daniel Henrique Barboza
There is a lot of Valgrind warnings about conditional jump depending on unintialized values like this one (taken from a pSeries guest): Conditional jump or move depends on uninitialised value(s) at 0xB011DC: kvmppc_enable_cap_large_decr (kvm.c:2544) by 0x92F28F: cap_large_decr_cpu_apply (

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Emanuele Giuseppe Esposito
Am 05/04/2022 um 12:14 schrieb Kevin Wolf: > I think all of this is really relevant for Emanuele's work, which > involves adding AIO_WAIT_WHILE() deep inside graph update functions. I > fully expect that we would see very similar problems, and just stacking > drain sections over drain sections t

Re: [PATCH v9 27/45] hw/cxl/host: Add support for CXL Fixed Memory Windows.

2022-04-05 Thread Markus Armbruster
Jonathan Cameron writes: > From: Jonathan Cameron > > The concept of these is introduced in [1] in terms of the > description the CEDT ACPI table. The principal is more general. > Unlike once traffic hits the CXL root bridges, the host system > memory address routing is implementation defined an

[PATCH v3 0/3] qcow2: Improve refcount structure rebuilding

2022-04-05 Thread Hanna Reitz
Hi, v2 cover letter: https://lists.nongnu.org/archive/html/qemu-block/2022-03/msg01260.html v1 cover letter: https://lists.nongnu.org/archive/html/qemu-block/2021-03/msg00651.html This series fixes the qcow2 refcount structure rebuilding mechanism for when the qcow2 image file doesn’t allow writ

[PATCH v3 1/3] qcow2: Improve refcount structure rebuilding

2022-04-05 Thread Hanna Reitz
When rebuilding the refcount structures (when qemu-img check -r found errors with refcount = 0, but reference count > 0), the new refcount table defaults to being put at the image file end[1]. There is no good reason for that except that it means we will not have to rewrite any refblocks we alread

[PATCH v3 3/3] qcow2: Add errp to rebuild_refcount_structure()

2022-04-05 Thread Hanna Reitz
Instead of fprint()-ing error messages in rebuild_refcount_structure() and its rebuild_refcounts_write_refblocks() helper, pass them through an Error object to qcow2_check_refcounts() (which will then print it). Suggested-by: Eric Blake Signed-off-by: Hanna Reitz --- block/qcow2-refcount.c | 33

[PATCH v3 2/3] iotests/108: Test new refcount rebuild algorithm

2022-04-05 Thread Hanna Reitz
One clear problem with how qcow2's refcount structure rebuild algorithm used to be before "qcow2: Improve refcount structure rebuilding" was that it is prone to failure for qcow2 images on block devices: There is generally unused space after the actual image, and if that exceeds what one refblock c

Re: [RFC PATCH] tests/qtest: attempt to enable tests for virtio-gpio (!working)

2022-04-05 Thread Alex Bennée
"Dr. David Alan Gilbert" writes: > * Alex Bennée (alex.ben...@linaro.org) wrote: >> >> (expanding the CC list for help, anyone have a better idea about how >> vhost-user qtests should work/see obvious issues with this patch?) > > How exactly does it fail? ➜ env QTEST_QEMU_BINARY=./qemu-syste

Re: [PATCH v3 2/5] tests/qtest/libqos/pci: Introduce pio_limit

2022-04-05 Thread Alex Bennée
Eric Auger writes: > At the moment the IO space limit is hardcoded to > QPCI_PIO_LIMIT = 0x1. When accesses are performed to a bar, > the base address of this latter is compared against the limit > to decide whether we perform an IO or a memory access. > > On ARM, we cannot keep this PIO li

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Kevin Wolf
Am 05.04.2022 um 13:47 hat Hanna Reitz geschrieben: > On 05.04.22 12:14, Kevin Wolf wrote: > > Am 24.03.2022 um 13:57 hat Hanna Reitz geschrieben: > > > When the stream block job cuts out the nodes between top and base in > > > stream_prepare(), it does not drain the subtree manually; it fetches th

Re: [PATCH 1/2] hw/xen/xen_pt: Confine igd-passthrough-isa-bridge to XEN

2022-04-05 Thread Anthony PERARD via
On Sat, Mar 26, 2022 at 05:58:23PM +0100, Bernhard Beschow wrote: > igd-passthrough-isa-bridge is only requested in xen_pt but was > implemented in pc_piix.c. This caused xen_pt to dependend on i386/pc > which is hereby resolved. > > Signed-off-by: Bernhard Beschow Acked-by: Anthony PERARD Tha

Re: [PATCH 2/2] hw/xen/xen_pt: Resolve igd_passthrough_isa_bridge_create() indirection

2022-04-05 Thread Anthony PERARD via
On Sat, Mar 26, 2022 at 05:58:24PM +0100, Bernhard Beschow wrote: > Now that igd_passthrough_isa_bridge_create() is implemented within the > xen context it may use Xen* data types directly and become > xen_igd_passthrough_isa_bridge_create(). This resolves an indirection. > > Signed-off-by: Bernha

[PATCH] docs/ccid: convert to restructuredText

2022-04-05 Thread oxr463
From: Lucas Ramage Buglink: https://gitlab.com/qemu-project/qemu/-/issues/527 Signed-off-by: Lucas Ramage --- docs/ccid.txt| 182 --- docs/system/device-emulation.rst | 1 + docs/system/devices/ccid.rst | 171 + 3

Re: [RFC PATCH 1/1] kvm-all.c: hint Valgrind that kvm_get_one_reg() inits memory

2022-04-05 Thread Peter Maydell
On Tue, 5 Apr 2022 at 14:07, Daniel Henrique Barboza wrote: > > There is a lot of Valgrind warnings about conditional jump depending on > unintialized values like this one (taken from a pSeries guest): > > Conditional jump or move depends on uninitialised value(s) > at 0xB011DC: kvmppc_enable

Re: [PATCH v3 3/5] tests/qtest/libqos: Skip hotplug tests if pci root bus is not hotpluggable

2022-04-05 Thread Alex Bennée
Eric Auger writes: > ARM does not not support hotplug on pcie.0. Add a flag on the bus > which tells if devices can be hotplugged and skip hotplug tests > if the bus cannot be hotplugged. This is a temporary solution to > enable the other pci tests on aarch64. > > Signed-off-by: Eric Auger > A

[PATCH v1] hw/ppc: change indentation to spaces from TABs

2022-04-05 Thread Guo Zhi
There are still some files in the QEMU PPC code base that use TABs for indentation instead of using spaces. The TABs should be replaced so that we have a consistent coding style. If this patch is applied, issue: https://gitlab.com/qemu-project/qemu/-/issues/374 can be closed. Signed-off-by: G

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Kevin Wolf
Am 05.04.2022 um 14:12 hat Vladimir Sementsov-Ogievskiy geschrieben: > Thanks Kevin! I have already run out of arguments in the battle > against using subtree-drains to isolate graph modification operations > from each other in different threads in the mailing list) > > (Note also, that the top-mo

[PATCH v1] configure: judge build dir permission

2022-04-05 Thread Guo Zhi
If this patch is applied, issue: https://gitlab.com/qemu-project/qemu/-/issues/321 can be closed. Signed-off-by: Guo Zhi --- configure | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/configure b/configure index 7c08c18358..9cfa78efd2 100755 --- a/configure +++ b/conf

Re: [PATCH] ui/cursor: fix integer overflow in cursor_alloc (CVE-2022-4206)

2022-04-05 Thread Mauro Matteo Cascella
On Tue, Apr 5, 2022 at 1:10 PM Gerd Hoffmann wrote: > > > > +++ b/ui/cursor.c > > > @@ -46,6 +46,13 @@ static QEMUCursor *cursor_parse_xpm(const char *xpm[]) > > > > > > /* parse pixel data */ > > > c = cursor_alloc(width, height); > > > + > > > +if (!c) { > > > +fprintf(stde

Re: [PATCH] block/stream: Drain subtree around graph change

2022-04-05 Thread Kevin Wolf
Am 05.04.2022 um 15:09 hat Emanuele Giuseppe Esposito geschrieben: > Am 05/04/2022 um 12:14 schrieb Kevin Wolf: > > I think all of this is really relevant for Emanuele's work, which > > involves adding AIO_WAIT_WHILE() deep inside graph update functions. I > > fully expect that we would see very si

Re: [RFC PATCH] docs/devel: start documenting writing VirtIO devices

2022-04-05 Thread Cornelia Huck
On Wed, Mar 16 2022, Alex Bennée wrote: > Cornelia Huck writes: > >> On Wed, Mar 09 2022, Alex Bennée wrote: >>> +Writing VirtIO backends for QEMU >>> + >>> + >>> +This document attempts to outline the information a developer needs to >>> +know to write backends

Re: [PULL 00/10] QAPI patches patches for 2022-04-05

2022-04-05 Thread Peter Maydell
On Tue, 5 Apr 2022 at 11:35, Markus Armbruster wrote: > > I double-checked these patches affect *only* generated documentation. > Safe enough for 7.0, I think. But I'm quite content to hold on to > them until after the release, if that's preferred. > > The following changes since commit 20661b75e

Re: [qemu.qmp PATCH 02/13] fork qemu.qmp from qemu.git

2022-04-05 Thread John Snow
On Tue, Apr 5, 2022, 4:51 AM Kashyap Chamarthy wrote: > On Mon, Apr 04, 2022 at 02:56:10PM -0400, John Snow wrote: > > On Mon, Apr 4, 2022 at 2:54 PM John Snow wrote: > > [...] > > > > > > .gitignore | 2 +- > > > > > Makefile | 16 > > > > > setup.cfg | 24 +---

[RFC v2 0/8] blkio: add libblkio BlockDriver

2022-04-05 Thread Stefan Hajnoczi
v2: - Add BDRV_REQ_REGISTERED_BUF to bs.supported_write_flags [Stefano] - Use new blkioq_get_num_completions() API - Implement .bdrv_refresh_limits() This patch series adds a QEMU BlockDriver for libblkio (https://gitlab.com/libblkio/libblkio/), a library for high-performance block device I/O. Cur

[RFC v2 3/8] block: pass size to bdrv_unregister_buf()

2022-04-05 Thread Stefan Hajnoczi
The only implementor of bdrv_register_buf() is block/nvme.c, where the size is not needed when unregistering a buffer. This is because util/vfio-helpers.c can look up mappings by address. Future block drivers that implement bdrv_register_buf() may not be able to do their job given only the buffer

[RFC v2 1/8] blkio: add io_uring block driver using libblkio

2022-04-05 Thread Stefan Hajnoczi
libblkio (https://gitlab.com/libblkio/libblkio/) is a library for high-performance disk I/O. It currently supports io_uring with additional drivers planned. One of the reasons for developing libblkio is that other applications besides QEMU can use it. This will be particularly useful for vhost-use

[RFC v2 4/8] block: add BDRV_REQ_REGISTERED_BUF request flag

2022-04-05 Thread Stefan Hajnoczi
Block drivers may optimize I/O requests accessing buffers previously registered with bdrv_register_buf(). Checking whether all elements of a request's QEMUIOVector are within previously registered buffers is expensive, so we need a hint from the user to avoid costly checks. Add a BDRV_REQ_REGISTER

[RFC v2 6/8] stubs: add memory_region_from_host() and memory_region_get_fd()

2022-04-05 Thread Stefan Hajnoczi
The blkio block driver will need to look up the file descriptor for a given pointer. This is possible in softmmu builds where the memory API is available for querying guest RAM. Add stubs so tools like qemu-img that link the block layer still build successfully. In this case there is no guest RAM

[RFC v2 2/8] numa: call ->ram_block_removed() in ram_block_notifer_remove()

2022-04-05 Thread Stefan Hajnoczi
When a RAMBlockNotifier is added, ->ram_block_added() is called with all existing RAMBlocks. There is no equivalent ->ram_block_removed() call when a RAMBlockNotifier is removed. The util/vfio-helpers.c code (the sole user of RAMBlockNotifier) is fine with this asymmetry because it does not rely o

[RFC v2 5/8] block: add BlockRAMRegistrar

2022-04-05 Thread Stefan Hajnoczi
Emulated devices and other BlockBackend users wishing to take advantage of blk_register_buf() all have the same repetitive job: register RAMBlocks with the BlockBackend using RAMBlockNotifier. Add a BlockRAMRegistrar API to do this. A later commit will use this from hw/block/virtio-blk.c. Signed-

[RFC v2 8/8] virtio-blk: use BDRV_REQ_REGISTERED_BUF optimization hint

2022-04-05 Thread Stefan Hajnoczi
Register guest RAM using BlockRAMRegistrar and set the BDRV_REQ_REGISTERED_BUF flag so block drivers can optimize memory accesses in I/O requests. This is for vdpa-blk, vhost-user-blk, and other I/O interfaces that rely on DMA mapping/unmapping. Signed-off-by: Stefan Hajnoczi --- include/hw/vir

[RFC v2 7/8] blkio: implement BDRV_REQ_REGISTERED_BUF optimization

2022-04-05 Thread Stefan Hajnoczi
Avoid bounce buffers when QEMUIOVector elements are within previously registered bdrv_register_buf() buffers. The idea is that emulated storage controllers will register guest RAM using bdrv_register_buf() and set the BDRV_REQ_REGISTERED_BUF on I/O requests. Therefore no blkio_add_mem_region() cal

Re: [PATCH] docs/ccid: convert to restructuredText

2022-04-05 Thread Damien Hedde
On 4/5/22 16:29, oxr...@gmx.us wrote: From: Lucas Ramage Buglink: https://gitlab.com/qemu-project/qemu/-/issues/527 Signed-off-by: Lucas Ramage Provided 2 minors tweaks (see below: missing empty line, and empty line at EOF), Reviewed-by: Damien Hedde Note that I'm not competent regard

Re: [RFC PATCH] docs/devel: start documenting writing VirtIO devices

2022-04-05 Thread Alex Bennée
Cornelia Huck writes: > On Wed, Mar 16 2022, Alex Bennée wrote: > >> Cornelia Huck writes: >> >>> On Wed, Mar 09 2022, Alex Bennée wrote: > +Writing VirtIO backends for QEMU + + +This document attempts to outline the information a developer

Re: [qemu.qmp PATCH 10/13] docs: add versioning policy to README

2022-04-05 Thread John Snow
On Tue, Apr 5, 2022, 5:16 AM Damien Hedde wrote: > > > On 3/30/22 20:24, John Snow wrote: > > The package is in an alpha state, but there's a method to the madness. > > > > Signed-off-by: John Snow > > --- > > README.rst | 21 + > > 1 file changed, 21 insertions(+) > > > >

Re: [PATCH v3 3/3] qcow2: Add errp to rebuild_refcount_structure()

2022-04-05 Thread Eric Blake
On Tue, Apr 05, 2022 at 03:46:52PM +0200, Hanna Reitz wrote: > Instead of fprint()-ing error messages in rebuild_refcount_structure() > and its rebuild_refcounts_write_refblocks() helper, pass them through an > Error object to qcow2_check_refcounts() (which will then print it). > > Suggested-by: E

Re: [PATCH v5 0/9] Add support for AST1030 SoC

2022-04-05 Thread Cédric Le Goater
Hello Jamin, On 4/1/22 10:38, Jamin Lin wrote: Changes from v5: - remove TYPE_ASPEED_MINIBMC_MACHINE and ASPEED_MINIBMC_MACHINE - remove ast1030_machine_instance_init function Changes from v4: - drop the ASPEED_SMC_FEATURE_WDT_CONTROL flag in hw/ssi/aspeed_smc.c Changes from v3: - remove Aspee

Re: [PATCH v4 10/11] tests/tcg/s390x: Tests for Vector Enhancements Facility 2

2022-04-05 Thread David Miller
Recommendation for comment? /* vri-d encoding matches vrr for 4b imm. .insn does not handle this encoding variant. */ Christian: I will push another patch version as soon as that's decided. (unless you prefer to choose the comment and edit during staging) On Tue, Apr 5, 2022 at 6:13 AM David H

  1   2   >