Re: [PATCH 06/19] block/stream: fix -Werror=maybe-uninitialized false-positives

2024-04-02 Thread Marc-André Lureau
Hi On Fri, Mar 29, 2024 at 12:35 PM Vladimir Sementsov-Ogievskiy wrote: > > On 28.03.24 13:20, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > ../block/stream.c:193:19: error: ‘unfiltered_bs’ may be used uninitialized > > [-Werror=maybe-uninitialized] > >

Re: [PATCH] block: Remove unnecessary NULL check in bdrv_pad_request()

2024-04-02 Thread Philippe Mathieu-Daudé
On 27/3/24 20:27, Kevin Wolf wrote: Coverity complains that the check introduced in commit 3f934817 suggests that qiov could be NULL and we dereference it before reaching the check. In fact, all of the callers pass a non-NULL pointer, so just remove the misleading check. Resolves: Coverity CID

Re: [PATCH 09/19] hw/sdhci: fix -Werror=maybe-uninitialized false-positive

2024-04-02 Thread Marc-André Lureau
Hi On Thu, Mar 28, 2024 at 3:31 PM Philippe Mathieu-Daudé wrote: > > On 28/3/24 11:20, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > ../hw/sd/sdhci.c:846:16: error: ‘res’ may be used uninitialized > > [-Werror=maybe-uninitialized] > > > > False-positive, because

Re: [PATCH 17/19] hw/nvme: fix -Werror=maybe-uninitialized

2024-04-02 Thread Klaus Jensen
On Mar 28 14:20, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > ../hw/nvme/ctrl.c:6081:21: error: ‘result’ may be used uninitialized > [-Werror=maybe-uninitialized] > > It's not obvious that 'result' is set in all code paths. When is > a returned argument, it's even less

Re: [PATCH 06/19] block/stream: fix -Werror=maybe-uninitialized false-positives

2024-04-02 Thread Vladimir Sementsov-Ogievskiy
On 02.04.24 12:12, Marc-André Lureau wrote: Hi On Fri, Mar 29, 2024 at 12:35 PM Vladimir Sementsov-Ogievskiy wrote: On 28.03.24 13:20, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau ../block/stream.c:193:19: error: ‘unfiltered_bs’ may be used uninitialized

[PULL 12/15] hw/nvme: fix -Werror=maybe-uninitialized

2024-04-02 Thread Philippe Mathieu-Daudé
From: Marc-André Lureau ../hw/nvme/ctrl.c:6081:21: error: ‘result’ may be used uninitialized [-Werror=maybe-uninitialized] It's not obvious that 'result' is set in all code paths. When is a returned argument, it's even less clear. Looking at various assignments, 0 seems to be a suitable

[PULL 01/15] accel/tcg/plugin: Remove CONFIG_SOFTMMU_GATE definition

2024-04-02 Thread Philippe Mathieu-Daudé
The CONFIG_SOFTMMU_GATE definition was never used, remove it. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Message-Id: <20240313213339.82071-2-phi...@linaro.org> --- accel/tcg/plugin-gen.c | 6 -- 1 file changed, 6 deletions(-) diff --git

[PULL 15/15] hw/net/virtio-net: fix qemu set used ring flag even vhost started

2024-04-02 Thread Philippe Mathieu-Daudé
From: Yajun Wu When vhost-user or vhost-kernel is handling virtio net datapath, QEMU should not touch used ring. But with vhost-user socket reconnect scenario, in a very rare case (has pending kick event). VRING_USED_F_NO_NOTIFY is set by QEMU in following code path: #0

[PULL 14/15] hw/xen_evtchn: Initialize flush_kvm_routes

2024-04-02 Thread Philippe Mathieu-Daudé
From: Artem Chernyshev In xen_evtchn_soft_reset() variable flush_kvm_routes can be used before being initialized. Found by Linux Verification Center (linuxtesting.org) with SVACE. Signed-off-by: Oleg Sviridov Signed-off-by: Artem Chernyshev Reviewed-by: Philippe Mathieu-Daudé Message-ID:

[PULL 09/15] hw/i386/pc: Restrict CXL to PCI-based machines

2024-04-02 Thread Philippe Mathieu-Daudé
CXL is based on PCIe. In is pointless to initialize its context on non-PCI machines. Signed-off-by: Philippe Mathieu-Daudé Acked-by: Jonathan Cameron Message-ID: <20240327161642.33574-1-phi...@linaro.org> --- hw/i386/pc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git

Re: [PATCH] block: Remove unnecessary NULL check in bdrv_pad_request()

2024-04-02 Thread Kevin Wolf
Am 02.04.2024 um 12:53 hat Philippe Mathieu-Daudé geschrieben: > On 27/3/24 20:27, Kevin Wolf wrote: > > Coverity complains that the check introduced in commit 3f934817 suggests > > that qiov could be NULL and we dereference it before reaching the check. > > In fact, all of the callers pass a

[PULL 05/15] hw/arm/smmu: Avoid using inlined functions with external linkage again

2024-04-02 Thread Philippe Mathieu-Daudé
Similarly to commit 9de9fa5cf2 ("hw/arm/smmu-common: Avoid using inlined functions with external linkage"): None of our code base require / use inlined functions with external linkage. Some places use internal inlining in the hot path. These two functions are certainly not in any hot path

[PULL 07/15] qtest/libqos: Reduce size_to_prdtl() declaration scope

2024-04-02 Thread Philippe Mathieu-Daudé
Since size_to_prdtl() is only used within ahci.c, declare it statically. This removes the last use of "inlined function with external linkage". See previous commit and commit 9de9fa5cf2 for rationale. Suggested-by: Peter Maydell Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Peter Maydell

[PULL 13/15] gpio/pca955x: Update maintainer email address

2024-04-02 Thread Philippe Mathieu-Daudé
From: Glenn Miles It was noticed that my linux.vnet.ibm.com address does not always work so dropping the vnet to see if that works better. Signed-off-by: Glenn Miles Message-ID: <20240328194914.2145709-1-mil...@linux.vnet.ibm.com> Signed-off-by: Philippe Mathieu-Daudé --- MAINTAINERS | 2 +-

[PULL 08/15] MAINTAINERS: Fix error-report.c entry

2024-04-02 Thread Philippe Mathieu-Daudé
From: Zhao Liu The commit 15002f60f792 ("util: rename qemu-error.c to match its header name") renamed util/qemu-error.c to util/error-report.c but missed to change the corresponding entry. To avoid get_maintainer.pl failing, update the error-report.c entry. Fixes: 15002f60f7 ("util: rename

Re: [PATCH 06/19] block/stream: fix -Werror=maybe-uninitialized false-positives

2024-04-02 Thread Eric Blake
On Tue, Apr 02, 2024 at 12:58:43PM +0300, Vladimir Sementsov-Ogievskiy wrote: > > > Again, same false-positives, because of WITH_GRAPH_RDLOCK_GUARD().. > > > > > > Didn't you try to change WITH_ macros somehow, so that compiler believe > > > in our good intentions? > > > > > > > > > #define

Re: [PULL 00/15] Misc HW patches for 2024-04-02

2024-04-02 Thread Peter Maydell
On Tue, 2 Apr 2024 at 15:25, Philippe Mathieu-Daudé wrote: > > The following changes since commit 7fcf7575f3d201fc84ae168017ffdfd6c86257a6: > > Merge tag 'pull-target-arm-20240402' of > https://git.linaro.org/people/pmaydell/qemu-arm into staging (2024-04-02 &

[PULL 02/15] gdbstub: Correct invalid mentions of 'softmmu' by 'system'

2024-04-02 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Message-Id: <20240313213339.82071-3-phi...@linaro.org> --- gdbstub/internals.h | 20 ++-- gdbstub/system.c| 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git

[PULL 04/15] target/ppc: Rename init_excp_4xx_softmmu() -> init_excp_4xx()

2024-04-02 Thread Philippe Mathieu-Daudé
Unify with other init_excp_FOO() in the same file. Signed-off-by: Philippe Mathieu-Daudé Acked-by: Nicholas Piggin Message-Id: <20240313213339.82071-5-phi...@linaro.org> --- target/ppc/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/ppc/cpu_init.c

[PULL 00/15] Misc HW patches for 2024-04-02

2024-04-02 Thread Philippe Mathieu-Daudé
The following changes since commit 7fcf7575f3d201fc84ae168017ffdfd6c86257a6: Merge tag 'pull-target-arm-20240402' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2024-04-02 11:34:49 +0100) are available in the Git repository at: https://github.com/philmd/qemu.git tags/hw

[PULL 11/15] plugins: fix -Werror=maybe-uninitialized false-positive

2024-04-02 Thread Philippe Mathieu-Daudé
From: Marc-André Lureau ../plugins/loader.c:405:15: error: ‘ctx’ may be used uninitialized [-Werror=maybe-uninitialized] Signed-off-by: Marc-André Lureau Reviewed-by: Pierrick Bouvier Message-ID: <20240328102052.3499331-15-marcandre.lur...@redhat.com> Signed-off-by: Philippe Mathieu-Daudé

Re: [PATCH v2 1/1] nbd/server: do not poll within a coroutine context

2024-04-02 Thread Zhu Yangyang via
On Mon, 1 Apr 2024 11:33:09AM -0500, Eric Blake wrote: > On Mon, Apr 01, 2024 at 08:41:20PM +0800, Zhu Yangyang wrote: > > Coroutines are not supposed to block. Instead, they should yield. > > > > Fixes: f95910f ("nbd: implement TLS support in the protocol negotiation") > > Signed-off-by: Zhu

[PULL 03/15] gdbstub/system: Rename 'user_ctx' argument as 'ctx'

2024-04-02 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-Id: <20240313213339.82071-4-phi...@linaro.org> --- gdbstub/internals.h | 8 gdbstub/system.c| 8 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/gdbstub/internals.h

[PULL 06/15] accel/hvf: Un-inline hvf_arch_supports_guest_debug()

2024-04-02 Thread Philippe Mathieu-Daudé
See previous commit and commit 9de9fa5cf2 ("Avoid using inlined functions with external linkage") for rationale. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Peter Maydell Reviewed-by: Richard Henderson Message-Id: <20240313184954.42513-3-phi...@linaro.org> --- target/arm/hvf/hvf.c | 2

[PULL 10/15] block: Remove unnecessary NULL check in bdrv_pad_request()

2024-04-02 Thread Philippe Mathieu-Daudé
From: Kevin Wolf Coverity complains that the check introduced in commit 3f934817 suggests that qiov could be NULL and we dereference it before reaching the check. In fact, all of the callers pass a non-NULL pointer, so just remove the misleading check. Resolves: Coverity CID 1542668

Re: [PATCH 06/19] block/stream: fix -Werror=maybe-uninitialized false-positives

2024-04-02 Thread Vladimir Sementsov-Ogievskiy
On 02.04.24 18:34, Eric Blake wrote: On Tue, Apr 02, 2024 at 12:58:43PM +0300, Vladimir Sementsov-Ogievskiy wrote: Again, same false-positives, because of WITH_GRAPH_RDLOCK_GUARD().. Didn't you try to change WITH_ macros somehow, so that compiler believe in our good intentions? #define

Re: [PATCH v2 2/4] mirror: allow specifying working bitmap

2024-04-02 Thread Vladimir Sementsov-Ogievskiy
On 07.03.24 16:47, Fiona Ebner wrote: From: John Snow for the mirror job. The bitmap's granularity is used as the job's granularity. The new @bitmap parameter is marked unstable in the QAPI and can currently only be used for @sync=full mode. Clusters initially dirty in the bitmap as well as

Re: [PATCH 13/19] hw/virtio-blk: fix -Werror=maybe-uninitialized false-positive

2024-04-02 Thread Stefan Hajnoczi
On Thu, Mar 28, 2024 at 02:20:46PM +0400, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > ../hw/block/virtio-blk.c:1212:12: error: ‘rq’ may be used uninitialized > [-Werror=maybe-uninitialized] > > Signed-off-by: Marc-André Lureau > --- > hw/block/virtio-blk.c | 2 +- > 1

Re: [PATCH-for-9.1 v2 2/3] migration: Remove RDMA protocol handling

2024-04-02 Thread Peter Xu
On Mon, Apr 01, 2024 at 11:26:25PM +0200, Yu Zhang wrote: > Hello Peter und Zhjian, > > Thank you so much for letting me know about this. I'm also a bit surprised at > the plan for deprecating the RDMA migration subsystem. It's not too late, since it looks like we do have users not yet notified

Re: [PATCH 01/19] util/coroutine: fix -Werror=maybe-uninitialized false-positive

2024-04-02 Thread Stefan Hajnoczi
On Thu, Mar 28, 2024 at 02:20:34PM +0400, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > ../util/qemu-coroutine.c:150:8: error: ‘batch’ may be used uninitialized > [-Werror=maybe-uninitialized] > > Signed-off-by: Marc-André Lureau > --- > util/qemu-coroutine.c | 2 +- > 1