Re: [PATCH v2 10/29] block/snapshot: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
On 11/03/2024 04.38, Zhao Liu wrote: From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to

[PULL 04/13] hw/core/loader-fit: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 08/13] hw/core: Cleanup unused included headers in cpu-common.c

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu Remove unused headers in cpu-common.c: * qemu/notify.h * exec/cpu-common.h * qemu/error-report.h * qemu/qemu-print.h Tested by "./configure" and then "make". Signed-off-by: Zhao Liu Reviewed-by: Philippe Mathieu-Daudé Message-ID:

Re: [PATCH v2 11/29] block/vdi: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
On 11/03/2024 04.38, Zhao Liu wrote: From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to

[PULL 11/13] hw/gpio: introduce pcf8574 driver

2024-03-12 Thread Philippe Mathieu-Daudé
From: Dmitriy Sharikhin NXP PCF8574 and compatible ICs are simple I2C GPIO expanders. PCF8574 incorporates quasi-bidirectional IO, and simple communication protocol, when IO read is I2C byte read, and IO write is I2C byte write. User can think of it as open-drain port, when line high state is

[PULL 01/13] hw/ide/ahci: Rename ahci_internal.h to ahci-internal.h

2024-03-12 Thread Philippe Mathieu-Daudé
From: BALATON Zoltan Other headers now use dash instead of underscore. Rename ahci_internal.h accordingly for consistency. Signed-off-by: BALATON Zoltan Reviewed-by: Markus Armbruster Reviewed-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé Message-ID:

[PULL 00/13] Misc HW patches for 2024-03-12

2024-03-12 Thread Philippe Mathieu-Daudé
The following changes since commit 7489f7f3f81dcb776df8c1b9a9db281fc21bf05f: Merge tag 'hw-misc-20240309' of https://github.com/philmd/qemu into staging (2024-03-09 20:12:21 +) are available in the Git repository at: https://github.com/philmd/qemu.git tags/hw-misc-20240312 for you

[PULL 03/13] hw/ppc/sam460ex: Support short options for adding drives

2024-03-12 Thread Philippe Mathieu-Daudé
From: BALATON Zoltan Having to use -drive if=none,... and -device ide-[cd,hd] is inconvenient. Add support for shorter convenience options such as -cdrom and -drive media=disk. Also adjust two nearby comments for code style. Signed-off-by: BALATON Zoltan Message-ID:

[PULL 05/13] hw/core/qdev-properties-system: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 02/13] hw/pci: add some convenient trace-events for pcie and shpc hotplug

2024-03-12 Thread Philippe Mathieu-Daudé
From: Vladimir Sementsov-Ogievskiy Add trace-events that may help to debug problems with hotplugging. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Philippe Mathieu-Daudé Message-ID: <20240301154146.761531-2-vsement...@yandex-team.ru> Signed-off-by: Philippe Mathieu-Daudé ---

[PULL 07/13] sun4u: remap ebus BAR0 to use unassigned_io_ops instead of alias to PCI IO space

2024-03-12 Thread Philippe Mathieu-Daudé
From: Mark Cave-Ayland During kernel startup OpenBSD accesses addresses mapped by BAR0 of the ebus device but at offsets where no IO devices exist. Before commit 4aa07e8649 ("hw/sparc64/ebus: Access memory regions via pci_address_space_io()") BAR0 was mapped to legacy IO space which allows

[PULL 10/13] hw/core: Cleanup unused included headers in numa.c

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu Remove unused header in numa.c: * qemu/bitmap.h * migration/vmstate.h Note: Though parse_numa_hmat_lb() has the variable named "bitmap_copy", it doesn't use the normal bitmap ops so that it's safe to exclude qemu/bitmap.h header. Tested by "./configure" and then "make".

[PULL 09/13] hw/core: Cleanup unused included header in machine-qmp-cmds.c

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu Remove unused header (qemu/main-loop.h) in machine-qmp-cmds.c. Tested by "./configure" and then "make". Signed-off-by: Zhao Liu Reviewed-by: Philippe Mathieu-Daudé Message-ID: <20240311075621.3224684-3-zhao1@linux.intel.com> Signed-off-by: Philippe Mathieu-Daudé ---

[PULL 13/13] docs/about/deprecated.rst: Move SMP configurations item to system emulator section

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu In the commit 54c4ea8f3ae6 ("hw/core/machine-smp: Deprecate unsupported 'parameter=1' SMP configurations"), the SMP related item is put under the section "User-mode emulator command line arguments" instead of "System emulator command line arguments". -smp is a system emulator

[PULL 12/13] meson.build: Always require an objc compiler on macos hosts

2024-03-12 Thread Philippe Mathieu-Daudé
From: Peter Maydell We currently only insist that an ObjectiveC compiler is present on macos hosts if we're building the Cocoa UI. However, since then we've added some other parts of QEMU which are also written in ObjC: the coreaudio audio backend, and the vmnet net backend. This means that if

[PULL 06/13] hw/misc/ivshmem: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Philippe Mathieu-Daudé
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

Re: [PATCH] virtio-blk: iothread-vq-mapping coroutine pool sizing

2024-03-12 Thread Kevin Wolf
Am 11.03.2024 um 21:14 hat Stefan Hajnoczi geschrieben: > It is possible to hit the sysctl vm.max_map_count limit when the > coroutine pool size becomes large. Each coroutine requires two mappings > (one for the stack and one for the guard page). QEMU can crash with > "failed to set up stack guard

Re: [PATCH v2] linux-aio: add IO_CMD_FDSYNC command support

2024-03-12 Thread Kevin Wolf
Am 11.03.2024 um 20:36 hat Stefan Hajnoczi geschrieben: > On Mon, Mar 11, 2024 at 04:40:05PM +0100, Kevin Wolf wrote: > > Am 11.03.2024 um 14:09 hat Stefan Hajnoczi geschrieben: > > > On Mon, Mar 11, 2024 at 11:13:33AM +0530, Prasad Pandit wrote: > > > > From: Prasad Pandit > > > > > > > >

Re: [PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Cédric Le Goater
On 3/12/24 13:04, Cédric Le Goater wrote: The block .save_setup() handler calls a helper routine init_blk_migration() which builds a list of block devices to take into account for migration. When one device is found to be empty (sectors == 0), the loop exits and all the remaining devices are

[PULL 11/55] block/nbd: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

Re: [PATCH v2 00/10] mirror: allow switching from background to active mode

2024-03-12 Thread Vladimir Sementsov-Ogievskiy
On 11.03.24 18:15, Vladimir Sementsov-Ogievskiy wrote: On 08.03.24 11:52, Kevin Wolf wrote: Am 07.03.2024 um 20:42 hat Vladimir Sementsov-Ogievskiy geschrieben: On 04.03.24 14:09, Peter Krempa wrote: On Mon, Mar 04, 2024 at 11:48:54 +0100, Kevin Wolf wrote: Am 28.02.2024 um 19:07 hat

Re: [PULL 0/6] hw/nvme updates

2024-03-12 Thread Peter Maydell
On Mon, 11 Mar 2024 at 19:11, Klaus Jensen wrote: > > From: Klaus Jensen > > Hi, > > The following changes since commit 7489f7f3f81dcb776df8c1b9a9db281fc21bf05f: > > Merge tag 'hw-misc-20240309' of https://github.com/philmd/qemu into staging > (2024-03-09 20:12:21 +) > > are available in

Re: [PATCH] virtio-blk: iothread-vq-mapping coroutine pool sizing

2024-03-12 Thread Stefan Hajnoczi
On Tue, Mar 12, 2024 at 12:24:30PM +0100, Kevin Wolf wrote: > Am 11.03.2024 um 21:14 hat Stefan Hajnoczi geschrieben: > > It is possible to hit the sysctl vm.max_map_count limit when the > > coroutine pool size becomes large. Each coroutine requires two mappings > > (one for the stack and one for

[PULL 15/55] block/qed: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 09/55] block: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 16/55] block/snapshot: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 14/55] block/qcow2: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 13/55] block/qcow2-bitmap: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 10/55] block/copy-before-write: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 17/55] block/vdi: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

[PULL 19/55] block/virtio-blk: Fix missing ERRP_GUARD() for error_prepend()

2024-03-12 Thread Thomas Huth
From: Zhao Liu As the comment in qapi/error, passing @errp to error_prepend() requires ERRP_GUARD(): * = Why, when and how to use ERRP_GUARD() = * * Without ERRP_GUARD(), use of the @errp parameter is restricted: ... * - It should not be passed to error_prepend(), error_vprepend() or *

Re: [PULL 0/6] hw/nvme updates

2024-03-12 Thread Klaus Jensen
On Mar 12 11:34, Peter Maydell wrote: > On Mon, 11 Mar 2024 at 19:11, Klaus Jensen wrote: > > > > From: Klaus Jensen > > > > Hi, > > > > The following changes since commit 7489f7f3f81dcb776df8c1b9a9db281fc21bf05f: > > > > Merge tag 'hw-misc-20240309' of https://github.com/philmd/qemu into > >

Re: [PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Peter Xu
On Tue, Mar 12, 2024 at 01:04:31PM +0100, Cédric Le Goater wrote: > The block .save_setup() handler calls a helper routine > init_blk_migration() which builds a list of block devices to take into > account for migration. When one device is found to be empty (sectors > == 0), the loop exits and all

[PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Cédric Le Goater
The block .save_setup() handler calls a helper routine init_blk_migration() which builds a list of block devices to take into account for migration. When one device is found to be empty (sectors == 0), the loop exits and all the remaining devices are ignored. This is a regression introduced when

Re: [PATCH v2] linux-aio: add IO_CMD_FDSYNC command support

2024-03-12 Thread Prasad Pandit
Hello, On Tue, 12 Mar 2024 at 15:15, Kevin Wolf wrote: > Am 11.03.2024 um 20:36 hat Stefan Hajnoczi geschrieben: > > > > That can be avoided with a variable that keeps track of whether -EINVAL > > > > was seen before and skips Linux AIO in that > > > > case. > > > > > > > > Fallback should be

[PATCH 04/10] qapi: Inline and remove QERR_DEVICE_NO_HOTPLUG definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Mechanical transformation using sed, and manual cleanup.

[PATCH 02/10] qapi: Inline and remove QERR_BUS_NO_HOTPLUG definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Mechanical transformation using sed, and manual cleanup.

[PATCH 00/10] Reduce usage of QERR_ macros further

2024-03-12 Thread Markus Armbruster
Philippe posted "[PATCH v2 00/22] qapi: Kill 'qapi/qmp/qerror.h' for good" a couple of months ago. I cherry-picked just its simplest parts for now. Markus Armbruster (1): error: Drop superfluous #include "qapi/qmp/qerror.h" Philippe Mathieu-Daudé (9): qapi: Inline and remove

[PATCH 06/10] qapi: Inline QERR_INVALID_PARAMETER_TYPE definition (constant value)

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Mechanical transformation using the following coccinelle semantic

[PATCH 08/10] qapi: Correct error message for 'vcpu_dirty_limit' parameter

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé QERR_INVALID_PARAMETER_VALUE is defined as: #define QERR_INVALID_PARAMETER_VALUE \ "Parameter '%s' expects %s" The current error is formatted as: "Parameter 'vcpu_dirty_limit' expects is invalid, it must greater then 1 MB/s" Replace by: "Parameter

[PATCH 07/10] qapi: Inline and remove QERR_INVALID_PARAMETER_TYPE definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Manual changes (escaping the format in qapi/visit.py).

Re: [PATCH v1 2/8] virtio-pci: Lock ioeventfd state with VIRTIO_F_NOTIFICATION_DATA

2024-03-12 Thread Jonah Palmer
On 3/11/24 11:47 AM, Michael S. Tsirkin wrote: On Mon, Mar 11, 2024 at 10:53:25AM -0400, Jonah Palmer wrote: On 3/8/24 2:19 PM, Michael S. Tsirkin wrote: On Fri, Mar 08, 2024 at 12:45:13PM -0500, Jonah Palmer wrote: On 3/8/24 12:36 PM, Eugenio Perez Martin wrote: On Fri, Mar 8, 2024

Re: [PATCH 04/10] qapi: Inline and remove QERR_DEVICE_NO_HOTPLUG definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:37PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:37 +0100 > From: Markus Armbruster > Subject: [PATCH 04/10] qapi: Inline and remove QERR_DEVICE_NO_HOTPLUG > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in commit

Re: [PATCH v1 2/8] virtio-pci: Lock ioeventfd state with VIRTIO_F_NOTIFICATION_DATA

2024-03-12 Thread Michael S. Tsirkin
On Tue, Mar 12, 2024 at 10:33:51AM -0400, Jonah Palmer wrote: > > > On 3/11/24 11:47 AM, Michael S. Tsirkin wrote: > > On Mon, Mar 11, 2024 at 10:53:25AM -0400, Jonah Palmer wrote: > > > > > > > > > On 3/8/24 2:19 PM, Michael S. Tsirkin wrote: > > > > On Fri, Mar 08, 2024 at 12:45:13PM -0500,

Re: [PATCH v7 2/4] qcow2: add configurations for zoned format extension

2024-03-12 Thread Stefan Hajnoczi
On Mon, Jan 22, 2024 at 07:48:28PM +0100, Sam Li wrote: > To configure the zoned format feature on the qcow2 driver, it > requires settings as: the device size, zone model, zone size, > zone capacity, number of conventional zones, limits on zone > resources (max append bytes, max open zones, and

[PATCH 10/10] qapi: Inline and remove QERR_PROPERTY_VALUE_BAD definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Manual change. Remove the definition in include/qapi/qmp/qerror.h.

[PATCH 03/10] qapi: Inline and remove QERR_DEVICE_HAS_NO_MEDIUM definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Mechanical transformation using sed, and manual cleanup.

Re: [PATCH 01/10] error: Drop superfluous #include "qapi/qmp/qerror.h"

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:34PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:34 +0100 > From: Markus Armbruster > Subject: [PATCH 01/10] error: Drop superfluous #include "qapi/qmp/qerror.h" > > Signed-off-by: Markus Armbruster > --- > backends/iommufd.c | 1 - >

Re: [PATCH 06/10] qapi: Inline QERR_INVALID_PARAMETER_TYPE definition (constant value)

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:39PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:39 +0100 > From: Markus Armbruster > Subject: [PATCH 06/10] qapi: Inline QERR_INVALID_PARAMETER_TYPE definition > (constant value) > > From: Philippe Mathieu-Daudé > > Address the comment added

Re: [PATCH v1 2/8] virtio-pci: Lock ioeventfd state with VIRTIO_F_NOTIFICATION_DATA

2024-03-12 Thread Jonah Palmer
On 3/12/24 10:58 AM, Michael S. Tsirkin wrote: On Tue, Mar 12, 2024 at 10:33:51AM -0400, Jonah Palmer wrote: On 3/11/24 11:47 AM, Michael S. Tsirkin wrote: On Mon, Mar 11, 2024 at 10:53:25AM -0400, Jonah Palmer wrote: On 3/8/24 2:19 PM, Michael S. Tsirkin wrote: On Fri, Mar 08, 2024

Re: [PATCH 08/10] qapi: Correct error message for 'vcpu_dirty_limit' parameter

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:41PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:41 +0100 > From: Markus Armbruster > Subject: [PATCH 08/10] qapi: Correct error message for 'vcpu_dirty_limit' > parameter > > From: Philippe Mathieu-Daudé > > QERR_INVALID_PARAMETER_VALUE is

[PATCH 09/10] qapi: Inline and remove QERR_MIGRATION_ACTIVE definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Mechanical transformation using sed, manually removing the

[PATCH 05/10] qapi: Inline and remove QERR_INVALID_PARAMETER definition

2024-03-12 Thread Markus Armbruster
From: Philippe Mathieu-Daudé Address the comment added in commit 4629ed1e98 ("qerror: Finally unused, clean up"), from 2015: /* * These macros will go away, please don't use * in new code, and do not add new ones! */ Mechanical transformation using: $ sed -i -e

[PATCH 01/10] error: Drop superfluous #include "qapi/qmp/qerror.h"

2024-03-12 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- backends/iommufd.c | 1 - chardev/char-fe.c | 1 - system/rtc.c | 1 - 3 files changed, 3 deletions(-) diff --git a/backends/iommufd.c b/backends/iommufd.c index 1ef683c7b0..922d75e49e 100644 --- a/backends/iommufd.c +++ b/backends/iommufd.c @@ -13,7

Re: [PATCH 05/10] qapi: Inline and remove QERR_INVALID_PARAMETER definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:38PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:38 +0100 > From: Markus Armbruster > Subject: [PATCH 05/10] qapi: Inline and remove QERR_INVALID_PARAMETER > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in commit

Re: [PATCH 09/10] qapi: Inline and remove QERR_MIGRATION_ACTIVE definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:42PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:42 +0100 > From: Markus Armbruster > Subject: [PATCH 09/10] qapi: Inline and remove QERR_MIGRATION_ACTIVE > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in commit

Re: [PATCH 07/10] qapi: Inline and remove QERR_INVALID_PARAMETER_TYPE definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:40PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:40 +0100 > From: Markus Armbruster > Subject: [PATCH 07/10] qapi: Inline and remove QERR_INVALID_PARAMETER_TYPE > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in

Re: [PATCH v2] linux-aio: add IO_CMD_FDSYNC command support

2024-03-12 Thread Stefan Hajnoczi
On Tue, Mar 12, 2024 at 07:07:04PM +0530, Prasad Pandit wrote: > Hello, > > On Tue, 12 Mar 2024 at 15:15, Kevin Wolf wrote: > > Am 11.03.2024 um 20:36 hat Stefan Hajnoczi geschrieben: > > > > > That can be avoided with a variable that keeps track of whether > > > > > -EINVAL was seen before and

Re: [PATCH 03/10] qapi: Inline and remove QERR_DEVICE_HAS_NO_MEDIUM definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:36PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:36 +0100 > From: Markus Armbruster > Subject: [PATCH 03/10] qapi: Inline and remove QERR_DEVICE_HAS_NO_MEDIUM > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in commit

Re: [PATCH 02/10] qapi: Inline and remove QERR_BUS_NO_HOTPLUG definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:35PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:35 +0100 > From: Markus Armbruster > Subject: [PATCH 02/10] qapi: Inline and remove QERR_BUS_NO_HOTPLUG > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in commit

Re: [PATCH 10/10] qapi: Inline and remove QERR_PROPERTY_VALUE_BAD definition

2024-03-12 Thread Zhao Liu
On Tue, Mar 12, 2024 at 03:13:43PM +0100, Markus Armbruster wrote: > Date: Tue, 12 Mar 2024 15:13:43 +0100 > From: Markus Armbruster > Subject: [PATCH 10/10] qapi: Inline and remove QERR_PROPERTY_VALUE_BAD > definition > > From: Philippe Mathieu-Daudé > > Address the comment added in commit

[PATCH v2] virtio-blk: iothread-vq-mapping coroutine pool sizing

2024-03-12 Thread Stefan Hajnoczi
It is possible to hit the sysctl vm.max_map_count limit when the coroutine pool size becomes large. Each coroutine requires two mappings (one for the stack and one for the guard page). QEMU can crash with "failed to set up stack guard page" or "failed to allocate memory for stack" when this

Re: [PATCH v2 00/10] mirror: allow switching from background to active mode

2024-03-12 Thread Kevin Wolf
Am 12.03.2024 um 14:44 hat Vladimir Sementsov-Ogievskiy geschrieben: > On 11.03.24 18:15, Vladimir Sementsov-Ogievskiy wrote: > > On 08.03.24 11:52, Kevin Wolf wrote: > > > Am 07.03.2024 um 20:42 hat Vladimir Sementsov-Ogievskiy geschrieben: > > > > On 04.03.24 14:09, Peter Krempa wrote: > > > > >

Re: [PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Stefan Hajnoczi
On Tue, Mar 12, 2024 at 09:22:06PM +0100, Cédric Le Goater wrote: > On 3/12/24 19:41, Stefan Hajnoczi wrote: > > On Tue, Mar 12, 2024 at 01:04:31PM +0100, Cédric Le Goater wrote: > > > The block .save_setup() handler calls a helper routine > > > init_blk_migration() which builds a list of block

[PULL 46/68] hw/pci: Always call pcie_sriov_pf_reset()

2024-03-12 Thread Michael S. Tsirkin
From: Akihiko Odaki Call pcie_sriov_pf_reset() from pci_do_device_reset() just as we do for msi_reset() and msix_reset() to prevent duplicating code for each SR-IOV PF. Signed-off-by: Akihiko Odaki Message-Id: <20240228-reuse-v8-5-282660281...@daynix.com> Reviewed-by: Michael S. Tsirkin

Re: [PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Peter Xu
On Tue, Mar 12, 2024 at 05:34:26PM -0400, Stefan Hajnoczi wrote: > I understand now. I missed that returning from init_blk_migration_it() > did not abort iteration. Thank you! I queued it, thanks both! -- Peter Xu

Re: [PATCH v6 3/3] hw/nvme: Add SPDM over DOE support

2024-03-12 Thread Michael S. Tsirkin
On Mon, Mar 11, 2024 at 11:15:37AM +1000, Alistair Francis wrote: > From: Wilfred Mallawa > > Setup Data Object Exchance (DOE) as an extended capability for the NVME > controller and connect SPDM to it (CMA) to it. > > Signed-off-by: Wilfred Mallawa > Signed-off-by: Alistair Francis >

[PULL 44/68] pcie_sriov: Reset SR-IOV extended capability

2024-03-12 Thread Michael S. Tsirkin
From: Akihiko Odaki pcie_sriov_pf_disable_vfs() is called when resetting the PF, but it only disables VFs and does not reset SR-IOV extended capability, leaking the state and making the VF Enable register inconsistent with the actual state. Replace pcie_sriov_pf_disable_vfs() with

[PULL 42/68] hw/nvme: Use pcie_sriov_num_vfs()

2024-03-12 Thread Michael S. Tsirkin
From: Akihiko Odaki nvme_sriov_pre_write_ctrl() used to directly inspect SR-IOV configurations to know the number of VFs being disabled due to SR-IOV configuration writes, but the logic was flawed and resulted in out-of-bound memory access. It assumed PCI_SRIOV_NUM_VF always has the number of

Re: [PATCH v2 00/15] hw/southbridge: Extract ICH9 QOM container model

2024-03-12 Thread Michael S. Tsirkin
On Mon, Feb 26, 2024 at 12:13:59PM +0100, Philippe Mathieu-Daudé wrote: > Since v1 [1]: > - Rebased on top of Bernhard patches > - Rename files with 'ich9_' prefix (Bernhard) > > Hi, > > I have a long standing southbridge QOM rework branches. Since > Bernhard is actively working on the PIIX,

Re: [PATCH] block: Use LVM tools for LV block device truncation

2024-03-12 Thread Alexander Ivanov
Thank you for the review. On 3/11/24 19:24, Daniel P. Berrangé wrote: On Mon, Mar 11, 2024 at 06:40:44PM +0100, Alexander Ivanov wrote: If a block device is an LVM logical volume we can resize it using standard LVM tools. In raw_co_truncate() check if the block device is a LV using lvdisplay

[PULL v2 1/6] hw/nvme: separate 'serial' property for VFs

2024-03-12 Thread Klaus Jensen
From: Minwoo Im Currently, when a VF is created, it uses the 'params' object of the PF as it is. In other words, the 'params.serial' string memory area is also shared. In this situation, if the VF is removed from the system, the PF's 'params.serial' object is released with object_finalize()

[PULL v2 2/6] hw/nvme: fix invalid check on mcl

2024-03-12 Thread Klaus Jensen
From: Klaus Jensen The number of logical blocks within a source range is converted into a 1s based number at the time of parsing. However, when verifying the copy length we add one again, causing the check against MCL to fail in error. Cc: qemu-sta...@nongnu.org Fixes: 381ab99d8587 ("hw/nvme:

[PULL v2 4/6] hw/nvme: Add NVMe NGUID property

2024-03-12 Thread Klaus Jensen
From: Roque Arcudia Hernandez This patch adds a way to specify an NGUID for a given NVMe Namespace using a string of hexadecimal digits with an optional '-' separator to group bytes. For instance: -device nvme-ns,nguid="e9accd3b83904e13167cf0593437f57d" If provided, the NGUID will be part of

[PULL v2 3/6] MAINTAINERS: add Jesper as reviewer on hw/nvme

2024-03-12 Thread Klaus Jensen
From: Klaus Jensen My colleague, Jesper, will be assiting with hw/nvme related reviews. Add him with R: so he gets automatically bugged going forward. Cc: Jesper Devantier Acked-by: Jesper Devantier Signed-off-by: Klaus Jensen --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff

Re: [PATCH 08/10] qapi: Correct error message for 'vcpu_dirty_limit' parameter

2024-03-12 Thread Philippe Mathieu-Daudé
On 12/3/24 16:26, Zhao Liu wrote: On Tue, Mar 12, 2024 at 03:13:41PM +0100, Markus Armbruster wrote: Date: Tue, 12 Mar 2024 15:13:41 +0100 From: Markus Armbruster Subject: [PATCH 08/10] qapi: Correct error message for 'vcpu_dirty_limit' parameter From: Philippe Mathieu-Daudé

Re: [PULL 00/13] Misc HW patches for 2024-03-12

2024-03-12 Thread Peter Maydell
in the Git repository at: > > https://github.com/philmd/qemu.git tags/hw-misc-20240312 > > for you to fetch changes up to afc8b05cea14b2eea6f1eaa640f74b21486fca48: > > docs/about/deprecated.rst: Move SMP configurations item to system emulato

[PULL v2 6/6] hw/nvme: add machine compatibility parameter to enable msix exclusive bar

2024-03-12 Thread Klaus Jensen
From: Klaus Jensen Commit 1901b4967c3f ("hw/block/nvme: move msix table and pba to BAR 0") moved the MSI-X table and PBA to BAR 0 to make room for enabling CMR and PMR at the same time. As reported by Julien Grall in #2184, this breaks migration through system hibernation. Add a machine

[PULL v2 0/6] hw/nvme updates

2024-03-12 Thread Klaus Jensen
From: Klaus Jensen Hi, Sorry about the compilation error in v1. Did a full CI run for v2. https://gitlab.com/birkelund/qemu/-/pipelines/1210559370 The following changes since commit 8f3f329f5e0117bd1a23a79ab751f8a7d3471e4b: Merge tag 'migration-20240311-pull-request' of

[PULL v2 5/6] hw/nvme: generalize the mbar size helper

2024-03-12 Thread Klaus Jensen
From: Klaus Jensen Generalize the mbar size helper such that it can handle cases where the MSI-X table and PBA are expected to be in an exclusive bar. Cc: qemu-sta...@nongnu.org Reviewed-by: Jesper Wendel Devantier Signed-off-by: Klaus Jensen --- hw/nvme/ctrl.c | 28

Re: [PATCH v2] virtio-blk: iothread-vq-mapping coroutine pool sizing

2024-03-12 Thread Michael S. Tsirkin
On Tue, Mar 12, 2024 at 11:12:04AM -0400, Stefan Hajnoczi wrote: > It is possible to hit the sysctl vm.max_map_count limit when the > coroutine pool size becomes large. Each coroutine requires two mappings > (one for the stack and one for the guard page). QEMU can crash with > "failed to set up

Re: [PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Cédric Le Goater
On 3/12/24 19:41, Stefan Hajnoczi wrote: On Tue, Mar 12, 2024 at 01:04:31PM +0100, Cédric Le Goater wrote: The block .save_setup() handler calls a helper routine init_blk_migration() which builds a list of block devices to take into account for migration. When one device is found to be empty

Re: [PATCH v7 3/4] qcow2: add zoned emulation capability

2024-03-12 Thread Stefan Hajnoczi
On Mon, Jan 22, 2024 at 07:48:29PM +0100, Sam Li wrote: > By adding zone operations and zoned metadata, the zoned emulation > capability enables full emulation support of zoned device using > a qcow2 file. The zoned device metadata includes zone type, > zoned device state and write pointer of each

Re: [PATCH v6 08/15] pcie_sriov: Reuse SR-IOV VF device instances

2024-03-12 Thread Michael S. Tsirkin
On Tue, Feb 20, 2024 at 09:24:43PM +0900, Akihiko Odaki wrote: > Disable SR-IOV VF devices by reusing code to power down PCI devices > instead of removing them when the guest requests to disable VFs. This > allows to realize devices and report VF realization errors at PF > realization time. > >

Re: [PATCH] block: Use LVM tools for LV block device truncation

2024-03-12 Thread Daniel P . Berrangé
On Tue, Mar 12, 2024 at 06:04:26PM +0100, Alexander Ivanov wrote: > Thank you for the review. > > On 3/11/24 19:24, Daniel P. Berrangé wrote: > > On Mon, Mar 11, 2024 at 06:40:44PM +0100, Alexander Ivanov wrote: > > > If a block device is an LVM logical volume we can resize it using > > >

Re: [PATCH v2 00/10] mirror: allow switching from background to active mode

2024-03-12 Thread Vladimir Sementsov-Ogievskiy
On 12.03.24 18:49, Kevin Wolf wrote: Am 12.03.2024 um 14:44 hat Vladimir Sementsov-Ogievskiy geschrieben: On 11.03.24 18:15, Vladimir Sementsov-Ogievskiy wrote: On 08.03.24 11:52, Kevin Wolf wrote: Am 07.03.2024 um 20:42 hat Vladimir Sementsov-Ogievskiy geschrieben: On 04.03.24 14:09, Peter

Re: [PATCH for 9.0] migration: Skip only empty block devices

2024-03-12 Thread Stefan Hajnoczi
On Tue, Mar 12, 2024 at 01:04:31PM +0100, Cédric Le Goater wrote: > The block .save_setup() handler calls a helper routine > init_blk_migration() which builds a list of block devices to take into > account for migration. When one device is found to be empty (sectors > == 0), the loop exits and all

Re: [PATCH v8 07/15] pcie_sriov: Do not manually unrealize

2024-03-12 Thread Michael S. Tsirkin
On Wed, Feb 28, 2024 at 08:33:18PM +0900, Akihiko Odaki wrote: > A device gets automatically unrealized when being unparented. > > Signed-off-by: Akihiko Odaki I was bisecting and when I bisected to this commit I got a build error: ../hw/pci/pcie_sriov.c: In function ‘register_vf’:

Re: [PATCH v6 07/15] pcie_sriov: Do not manually unrealize

2024-03-12 Thread Michael S. Tsirkin
On Tue, Feb 20, 2024 at 09:24:42PM +0900, Akihiko Odaki wrote: > A device gets automatically unrealized when being unparented. > > Signed-off-by: Akihiko Odaki > --- > hw/pci/pcie_sriov.c | 5 - > 1 file changed, 5 deletions(-) > > diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c >

Re: [PATCH v8 00/15] hw/pci: SR-IOV related fixes and improvements

2024-03-12 Thread Michael S. Tsirkin
On Wed, Feb 28, 2024 at 08:33:11PM +0900, Akihiko Odaki wrote: > I submitted a RFC series[1] to add support for SR-IOV emulation to > virtio-net-pci. During the development of the series, I fixed some > trivial bugs and made improvements that I think are independently > useful. This series