Re: [PATCH v4 16/25] vfio: Add Error** argument to .set_dirty_page_tracking() handler

2024-03-07 Thread Eric Auger
Hi Cédric, On 3/6/24 14:34, Cédric Le Goater wrote: > We will use the Error object to improve error reporting in the > .log_global*() handlers of VFIO. Add documentation while at it. > > Reviewed-by: Philippe Mathieu-Daudé > Signed-off-by: Cédric Le Goater > --- > > Changes in v3: > > - Use

Re: [PATCH v4 17/25] vfio: Add Error** argument to vfio_devices_dma_logging_start()

2024-03-07 Thread Eric Auger
Hi Cédric, On 3/6/24 14:34, Cédric Le Goater wrote: > This allows to update the Error argument of the VFIO log_global_start() > handler. Errors detected when device level logging is started will be > propagated up to qemu_savevm_state_setup() when the ram save_setup() > handler is executed. > > T

Re: [PATCH RESEND v3 3/3] docs/system: Add recommendations to Hyper-V enlightenments doc

2024-03-07 Thread Zhao Liu
Hi Vitaly, On Tue, Mar 05, 2024 at 05:42:04PM +0100, Vitaly Kuznetsov wrote: > Date: Tue, 5 Mar 2024 17:42:04 +0100 > From: Vitaly Kuznetsov > Subject: [PATCH RESEND v3 3/3] docs/system: Add recommendations to Hyper-V > enlightenments doc > > While hyperv.rst already has all currently implemen

Re: [PATCH v5 30/65] i386/tdx: Support user configurable mrconfigid/mrowner/mrownerconfig

2024-03-07 Thread Markus Armbruster
Xiaoyao Li writes: > On 2/29/2024 9:25 PM, Markus Armbruster wrote: >> Xiaoyao Li writes: >> >>> On 2/29/2024 4:37 PM, Markus Armbruster wrote: Xiaoyao Li writes: > From: Isaku Yamahata > > Three sha384 hash values, mrconfigid, mrowner and mrownerconfig, of a TD > ca

Re: [PATCH v4 18/25] vfio: Add Error** argument to vfio_devices_dma_logging_stop()

2024-03-07 Thread Eric Auger
On 3/6/24 14:34, Cédric Le Goater wrote: > This improves error reporting in the log_global_stop() VFIO handler. > > Reviewed-by: Philippe Mathieu-Daudé > Signed-off-by: Cédric Le Goater > --- > > Changes in v4: > > - Dropped log_global_stop() and log_global_sync() changes > > Changes

Re: [PATCH v4 19/25] vfio: Use new Error** argument in vfio_save_setup()

2024-03-07 Thread Eric Auger
Hi Cédric, On 3/6/24 14:34, Cédric Le Goater wrote: > Add an Error** argument to vfio_migration_set_state() and adjust > callers, including vfio_save_setup(). The error will be propagated up > to qemu_savevm_state_setup() where the save_setup() handler is > executed. > > Modify vfio_vmstate_chang

Re: [PULL 0/4] machine development tool

2024-03-07 Thread Maksim Davydov
On 3/6/24 04:57, Peter Xu wrote: On Tue, Mar 05, 2024 at 03:43:41PM +0100, Markus Armbruster wrote: Peter Maydell writes: On Mon, 4 Mar 2024 at 13:52, Maksim Davydov wrote: The following changes since commit e1007b6bab5cf97705bf4f2aaec1f607787355b8: Merge tag 'pull-request-2024-03-01'

Re: [PATCH v4 20/25] vfio: Add Error** argument to .vfio_save_config() handler

2024-03-07 Thread Eric Auger
On 3/6/24 14:34, Cédric Le Goater wrote: > Use vmstate_save_state_with_err() to improve error reporting in the > callers and store a reported error under the migration stream. Add > documentation while at it. > > Reviewed-by: Philippe Mathieu-Daudé > Signed-off-by: Cédric Le Goater > --- > i

Re: [PATCH v2 2/6] qdev-monitor: fix error message in find_device_state()

2024-03-07 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > This "hotpluggable" here is misleading. Actually we check is object a > device or not. Let's drop the word. > > SUggested-by: Markus Armbruster "Suggested" > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > system/qdev-monitor.c | 2 +- > 1 file chan

Re: [RFC 0/4] mirror: implement incremental and bitmap modes

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 06.03.24 16:44, Fiona Ebner wrote: Am 29.02.24 um 13:47 schrieb Fiona Ebner: Am 29.02.24 um 12:48 schrieb Vladimir Sementsov-Ogievskiy: On 29.02.24 13:11, Fiona Ebner wrote: The iotest creates a new target image for each incremental sync which only records the diff relative to the previous

Re: [PATCH v2 1/2] hw/arm/virt-acpi-build.c: Migrate SPCR creation to common location

2024-03-07 Thread Daniel Henrique Barboza
On 3/7/24 00:45, Sunil V L wrote: On Thu, Mar 07, 2024 at 11:33:25AM +1000, Alistair Francis wrote: On Thu, Mar 7, 2024 at 4:59 AM Daniel Henrique Barboza wrote: Hi, This patch break check-qtest, most specifically 'bios-table'test', for aarch64. I found this while running riscv-to-apply.n

Re: [PATCH v4 23/25] vfio: Add Error** argument to .get_dirty_bitmap() handler

2024-03-07 Thread Eric Auger
On 3/6/24 14:34, Cédric Le Goater wrote: > Let the callers do the error reporting. Add documentation while at it. > > Signed-off-by: Cédric Le Goater > --- > include/hw/vfio/vfio-common.h | 4 +- > include/hw/vfio/vfio-container-base.h | 17 +++- > hw/vfio/common.c

Re: [PATCH v5 5/5] target/riscv: Implement privilege mode filtering for cycle/instret

2024-03-07 Thread Atish Patra
On 3/4/24 22:47, LIU Zhiwei wrote: On 2024/2/29 2:51, Atish Patra wrote: Privilege mode filtering can also be emulated for cycle/instret by tracking host_ticks/icount during each privilege mode switch. This patch implements that for both cycle/instret and mhpmcounters. The first one requires

Re: [PATCH v5 2/5] target/riscv: Add cycle & instret privilege mode filtering properties

2024-03-07 Thread Atish Patra
On 3/4/24 23:01, LIU Zhiwei wrote: On 2024/2/29 2:51, Atish Patra wrote: From: Kaiwen Xue This adds the properties for ISA extension smcntrpmf. Patches implementing it will follow. Signed-off-by: Atish Patra Signed-off-by: Kaiwen Xue ---   target/riscv/cpu.c | 2 ++   target/riscv/cpu

Re: [PATCH v4 24/25] vfio: Also trace event failures in vfio_save_complete_precopy()

2024-03-07 Thread Eric Auger
On 3/6/24 14:34, Cédric Le Goater wrote: > vfio_save_complete_precopy() currently returns before doing the trace > event. Change that. > > Signed-off-by: Cédric Le Goater > --- > hw/vfio/migration.c | 3 --- > 1 file changed, 3 deletions(-) > > diff --git a/hw/vfio/migration.c b/hw/vfio/migr

Re: [PATCH v4 25/25] vfio: Extend vfio_set_migration_error() with Error* argument

2024-03-07 Thread Eric Auger
Hi Cédric, On 3/6/24 14:34, Cédric Le Goater wrote: > vfio_set_migration_error() sets the 'return' error on the migration > stream if a migration is in progress. To improve error reporting, add > a new Error* argument to also set the Error object on the migration > stream, if a migration is progre

Re: [PATCH v8 2/2] hw/acpi: Implement the SRAT GI affinity structure

2024-03-07 Thread Jonathan Cameron via
On Thu, 7 Mar 2024 03:03:02 + Ankit Agrawal wrote: > >> > >> [1] ACPI Spec 6.3, Section 5.2.16.6 > >> [2] ACPI Spec 6.3, Table 5.80 > >> > >> Cc: Jonathan Cameron > >> Cc: Alex Williamson > >> Cc: Cedric Le Goater > >> Signed-off-by: Ankit Agrawal > > > > I guess we gloss over the bisec

Re: [PATCH v4 06/25] vfio: Always report an error in vfio_save_setup()

2024-03-07 Thread Eric Auger
On 3/6/24 14:34, Cédric Le Goater wrote: > This will prepare ground for future changes adding an Error** argument > to the save_setup() handler. We need to make sure that on failure, > vfio_save_setup() always sets a new error. > > Reviewed-by: Fabiano Rosas > Signed-off-by: Cédric Le Goater

Re: [PATCH 1/3] ui/gtk: skip drawing guest scanout when associated VC is invisible

2024-03-07 Thread Daniel P . Berrangé
On Tue, Jan 30, 2024 at 03:48:38PM -0800, dongwon@intel.com wrote: > From: Dongwon Kim > > A new flag "visible" is added to show visibility status of the gfx console. > The flag is set to 'true' when the VC is visible but set to 'false' when > it is hidden or closed. When the VC is invisible,

Re: [PATCH v5 0/3] Initial support for SPDM Responders

2024-03-07 Thread Jonathan Cameron via
On Thu, 7 Mar 2024 10:58:56 +1000 Alistair Francis wrote: > The Security Protocol and Data Model (SPDM) Specification defines > messages, data objects, and sequences for performing message exchanges > over a variety of transport and physical media. > - > https://www.dmtf.org/sites/default/file

Re: [PATCH RESEND v3 3/3] docs/system: Add recommendations to Hyper-V enlightenments doc

2024-03-07 Thread Vitaly Kuznetsov
Zhao Liu writes: > Hi Vitaly, > > On Tue, Mar 05, 2024 at 05:42:04PM +0100, Vitaly Kuznetsov wrote: >> Date: Tue, 5 Mar 2024 17:42:04 +0100 >> From: Vitaly Kuznetsov >> Subject: [PATCH RESEND v3 3/3] docs/system: Add recommendations to Hyper-V >> enlightenments doc >> >> While hyperv.rst alre

Re: [PATCH 1/3] ui/gtk: skip drawing guest scanout when associated VC is invisible

2024-03-07 Thread Daniel P . Berrangé
On Thu, Feb 01, 2024 at 06:48:58PM +, Kim, Dongwon wrote: > Hi Marc-André, > > Thanks for your feedback. Yes, you are right, rendering doesn't stop on > Ubuntu system > as it has preview even after the window is minimized. But this is not always > the case. > Some simple windows managers don

Re: [PATCH v2 3/6] qdev-monitor: add option to report GenericError from find_device_state

2024-03-07 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > system/qdev-monitor.c | 15 +++ > 1 file changed, 11 insertions(+), 4 deletions(-) > > diff --git a/system/qdev-monitor.c b/system/qdev-monitor.c > index 9febb743f1..cf7481e416 100644 > --- a/

Re: [PATCH 2/3] ui/gtk: set the ui size to 0 when invisible

2024-03-07 Thread Daniel P . Berrangé
On Wed, Jan 31, 2024 at 11:12:57AM +0400, Marc-André Lureau wrote: > Hi > > On Wed, Jan 31, 2024 at 3:50 AM wrote: > > > > From: Dongwon Kim > > > > UI size is set to 0 when the VC is invisible, which will prevent > > the further scanout update by notifying the guest that the display > > is not

Re: [PATCH 0/3] ui/gtk: introducing vc->visible

2024-03-07 Thread Daniel P . Berrangé
On Tue, Mar 05, 2024 at 04:18:18PM +0400, Marc-André Lureau wrote: > Hi Kim > > I am uncomfortable with the series in general. > > Not only we don't have the means to draw dmabuf/scanout "when > required", so resuming drawing won't work until the guest draws (this > is already a problem but you a

Re: [PATCH v2 4/6] qapi: introduce device-sync-config

2024-03-07 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Add command to sync config from vhost-user backend to the device. It > may be helpful when VHOST_USER_SLAVE_CONFIG_CHANGE_MSG failed or not > triggered interrupt to the guest or just not available (not supported > by vhost-user server). > > Signed-off-by: Vl

Re: [PATCH v4 11/25] migration: Add Error** argument to .save_setup() handler

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 06.03.24 16:34, Cédric Le Goater wrote: The purpose is to record a potential error in the migration stream if qemu_savevm_state_setup() fails. Most of the current .save_setup() handlers can be modified to use the Error argument instead of managing their own and calling locally error_report().

Re: [PATCH] input-linux: Add option to not grab a device upon guest startup

2024-03-07 Thread Daniel P . Berrangé
On Wed, Mar 06, 2024 at 10:28:22PM -0800, Justinien Bouron wrote: > Depending on your use-case, it might be inconvenient to have qemu grab > the input device immediately upon starting the guest, especially if the > guest takes a while to start in which case it may take a few seconds > before being

Re: [PATCH v2 5/6] qapi: device-sync-config: check runstate

2024-03-07 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Command result is racy if allow it during migration. Let's allow the > sync only in RUNNING state. > > Signed-off-by: Vladimir Sementsov-Ogievskiy If I understand this correctly, the previous commit introduces a race, and this one fixes it. We normally av

Re: [PATCH v2 6/6] qapi: introduce CONFIG_READ event

2024-03-07 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Send a new event when guest reads virtio-pci config after > virtio_notify_config() call. > > That's useful to check that guest fetched modified config, for example > after resizing disk backend. > > Signed-off-by: Vladimir Sementsov-Ogievskiy [...] > diff

Re: [PATCH v2 3/6] qdev-monitor: add option to report GenericError from find_device_state

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 07.03.24 12:46, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: Signed-off-by: Vladimir Sementsov-Ogievskiy --- system/qdev-monitor.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/system/qdev-monitor.c b/system/qdev-monitor.c index 9f

Re: [PATCH v2 4/6] qapi: introduce device-sync-config

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 07.03.24 12:54, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: Add command to sync config from vhost-user backend to the device. It may be helpful when VHOST_USER_SLAVE_CONFIG_CHANGE_MSG failed or not triggered interrupt to the guest or just not available (not supported by vh

Re: [PATCH v2 8/9] Hexagon (target/hexagon) Remove gen_shortcode.py

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 04:23, Taylor Simpson wrote: This data structure is not used Signed-off-by: Taylor Simpson --- target/hexagon/opcodes.c| 7 target/hexagon/README | 1 - target/hexagon/gen_shortcode.py | 63 - target/hexagon/meson.build

Re: [PATCH v2 9/9] Hexagon (target/hexagon) Remove hex_common.read_attribs_file

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 04:23, Taylor Simpson wrote: The attribinfo data structure is not used Adjust the command-line arguments to the python scripts Add hex_common.read_common_files for TCG/helper generation scripts Signed-off-by: Taylor Simpson --- target/hexagon/gen_analyze_funcs.py | 21 ++

Re: [PATCH v5 2/3] backends: Initial support for SPDM socket support

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 01:58, Alistair Francis wrote: From: Huai-Cheng Kuo SPDM enables authentication, attestation and key exchange to assist in providing infrastructure security enablement. It's a standard published by the DMTF [1]. SPDM supports multiple transports, including PCIe DOE and MCTP. This pat

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

2024-03-07 Thread Philippe Mathieu-Daudé
Hi Alistair, Wilfred, On 7/3/24 01:58, 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 Reviewed-by: Jonathan Ca

[PATCH v4 05/19] contrib/elf2dmp: Fix error reporting style in addrspace.c

2024-03-07 Thread Akihiko Odaki
include/qapi/error.h says: > We recommend > * bool-valued functions return true on success / false on failure, > ... Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/addrspace.h | 4 ++-- contrib/elf2dmp/addrspace.c | 8 contrib/elf2dmp/main.c | 47 +--

[PATCH v4 00/19] contrib/elf2dmp: Improve robustness

2024-03-07 Thread Akihiko Odaki
elf2dmp sometimes fails to work with partially corrupted dumps, and also emits warnings when sanitizers are in use. This series are collections of changes to improve the situation. Signed-off-by: Akihiko Odaki --- Changes in v4: - Remove unnecessary !! idiom (Peter Maydell) - Link to v3: https:/

[PATCH v4 04/19] contrib/elf2dmp: Change pa_space_create() signature

2024-03-07 Thread Akihiko Odaki
pa_space_create() used to return an integer to propagate error, but it never fails so let it return void. Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/addrspace.h | 2 +- contrib/elf2dmp/addrspace.c | 4 +--- contrib/elf2dmp/main.c | 5 + 3 files changed, 3 insertions(+), 8 deletion

[PATCH v4 11/19] contrib/elf2dmp: Always destroy PA space

2024-03-07 Thread Akihiko Odaki
Destroy PA space even if paging base couldn't be found, fixing memory leak. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/main.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/contrib/elf2dmp/main.c b/contrib/elf2dmp/main.c index 9347b0cd5a2d

[PATCH v4 01/19] contrib/elf2dmp: Remove unnecessary err flags

2024-03-07 Thread Akihiko Odaki
They are always evaluated to 1. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/pdb.c | 14 +++--- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/contrib/elf2dmp/pdb.c b/contrib/elf2dmp/pdb.c index 40991f5f4c34..abf17c2e7c12 100644 --- a/contr

[PATCH v4 06/19] contrib/elf2dmp: Fix error reporting style in download.c

2024-03-07 Thread Akihiko Odaki
include/qapi/error.h says: > We recommend > * bool-valued functions return true on success / false on failure, > ... Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/download.h | 2 +- contrib/elf2dmp/download.c | 10 +- contrib/elf2dmp/main.c | 2 +- 3 files changed, 7 insertions(

[PATCH v4 19/19] contrib/elf2dmp: Ensure phdrs fit in file

2024-03-07 Thread Akihiko Odaki
Callers of elf64_getphdr() and elf_getphdrnum() assume phdrs are accessible. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2202 Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/qemu_elf.c | 8 1 file changed, 8 insertions(+) diff --git a/contrib/elf2dmp/qemu_elf.c b/contrib/e

[PATCH v4 14/19] contrib/elf2dmp: Use rol64() to decode

2024-03-07 Thread Akihiko Odaki
rol64() is roubust against too large shift values and fixes UBSan warnings. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/main.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/contrib/elf2dmp/main.c b/contrib/elf2dmp/main.c index 32dc8b

[PATCH v4 02/19] contrib/elf2dmp: Assume error by default

2024-03-07 Thread Akihiko Odaki
A common construct in contrib/elf2dmp is to set "err" flag and goto in error paths. In such a construct, there is only one successful path while there are several error paths, so it will be more simpler to initialize "err" flag set, and clear it in the successful path. Signed-off-by: Akihiko Odaki

[PATCH v4 13/19] contrib/elf2dmp: Use lduw_le_p() to read PDB

2024-03-07 Thread Akihiko Odaki
The relevant value may be unaligned and is little-endian. Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/pdb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/elf2dmp/pdb.c b/contrib/elf2dmp/pdb.c index 1c5051425185..492aca4434c8 100644 --- a/contrib/elf2dmp/pdb.c

[PATCH v4 18/19] contrib/elf2dmp: Clamp QEMU note to file size

2024-03-07 Thread Akihiko Odaki
This fixes crashes with truncated dumps. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/qemu_elf.c | 87 +- 1 file changed, 55 insertions(+), 32 deletions(-) diff --git a/contrib/elf2dmp/qemu_elf.c b/contrib/elf2dmp/qemu_

[PATCH v4 12/19] contrib/elf2dmp: Ensure segment fits in file

2024-03-07 Thread Akihiko Odaki
This makes elf2dmp more robust against corrupted inputs. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/addrspace.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/contrib/elf2dmp/addrspace.c b/contrib/elf2dmp/addrspace.c index e01860d15b07.

[PATCH v4 17/19] contrib/elf2dmp: Use GPtrArray

2024-03-07 Thread Akihiko Odaki
This removes the need to enumarate QEMUCPUState twice and saves code. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/qemu_elf.c | 25 - 1 file changed, 8 insertions(+), 17 deletions(-) diff --git a/contrib/elf2dmp/qemu_elf.c b/contrib/elf2dm

[PATCH v4 03/19] contrib/elf2dmp: Continue even contexts are lacking

2024-03-07 Thread Akihiko Odaki
Let fill_context() continue even if it fails to fill contexts of some CPUs. A dump may still contain valuable information even if it lacks contexts of some CPUs due to dump corruption or a failure before starting CPUs. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/

[PATCH v4 08/19] contrib/elf2dmp: Fix error reporting style in qemu_elf.c

2024-03-07 Thread Akihiko Odaki
include/qapi/error.h says: > We recommend > * bool-valued functions return true on success / false on failure, > ... Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/qemu_elf.h | 2 +- contrib/elf2dmp/main.c | 2 +- contrib/elf2dmp/qemu_elf.c | 32 3 files

Re: [PATCH v7 4/9] qemu-options.hx: Document the virtio-iommu-pci granule option

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 08:32, Eric Auger wrote: Hi Philippe, On 3/6/24 21:44, Philippe Mathieu-Daudé wrote: On 6/3/24 21:32, Eric Auger wrote: We are missing an entry for the virtio-iommu-pci device. Add the information on which machine it is currently supported and document the new granule option. Signed

[PATCH v4 09/19] contrib/elf2dmp: Fix error reporting style in main.c

2024-03-07 Thread Akihiko Odaki
include/qapi/error.h says: > We recommend > * bool-valued functions return true on success / false on failure, > ... Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/main.c | 63 +- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/co

[PATCH v4 15/19] MAINTAINERS: Add Akihiko Odaki as a elf2dmp reviewer

2024-03-07 Thread Akihiko Odaki
Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 65dfdc9677e4..d25403f3709b 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3583,6 +3583,7 @@ F: util/iova-tree.c elf2dmp M: Viktor Prutya

[PATCH v4 07/19] contrib/elf2dmp: Fix error reporting style in pdb.c

2024-03-07 Thread Akihiko Odaki
include/qapi/error.h says: > We recommend > * bool-valued functions return true on success / false on failure, > ... Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/pdb.h | 2 +- contrib/elf2dmp/main.c | 2 +- contrib/elf2dmp/pdb.c | 50 +- 3

[PATCH v4 16/19] contrib/elf2dmp: Build only for little endian host

2024-03-07 Thread Akihiko Odaki
elf2dmp assumes little endian host in many places. Build it only for little endian hosts until they are fixed. Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/elf2dmp/meson.build b/contrib/elf2dmp/meson.buil

[PATCH v4 10/19] contrib/elf2dmp: Always check for PA resolution failure

2024-03-07 Thread Akihiko Odaki
Not checking PA resolution failure can result in NULL deference. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/addrspace.c | 46 - 1 file changed, 29 insertions(+), 17 deletions(-) diff --git a/contrib/elf2dmp/addrspace.

Re: [PATCH v4 04/19] contrib/elf2dmp: Change pa_space_create() signature

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 11:20, Akihiko Odaki wrote: pa_space_create() used to return an integer to propagate error, but it never fails so let it return void. Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/addrspace.h | 2 +- contrib/elf2dmp/addrspace.c | 4 +--- contrib/elf2dmp/main.c | 5 +

Re: [PATCH v4 05/19] contrib/elf2dmp: Fix error reporting style in addrspace.c

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 11:20, Akihiko Odaki wrote: include/qapi/error.h says: We recommend * bool-valued functions return true on success / false on failure, ... Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/addrspace.h | 4 ++-- contrib/elf2dmp/addrspace.c | 8 contrib/elf2dmp/main.c

Re: [PATCH v4 13/19] contrib/elf2dmp: Use lduw_le_p() to read PDB

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 11:20, Akihiko Odaki wrote: The relevant value may be unaligned and is little-endian. Fixes: 231f6a7d66 ("elf2dmp: rework PDB_STREAM_INDEXES::segments obtaining") Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Akihiko Odaki --- contrib/elf2dmp/pdb.c | 3 ++- 1 file changed

Re: [PATCH v4 15/19] MAINTAINERS: Add Akihiko Odaki as a elf2dmp reviewer

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 11:20, Akihiko Odaki wrote: Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH v4 14/19] contrib/elf2dmp: Use rol64() to decode

2024-03-07 Thread Philippe Mathieu-Daudé
On 7/3/24 11:20, Akihiko Odaki wrote: rol64() is roubust against too large shift values and fixes UBSan warnings. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell --- contrib/elf2dmp/main.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) Reviewed-by: Philippe Mathieu-

Re: [PATCH v4 11/25] migration: Add Error** argument to .save_setup() handler

2024-03-07 Thread Cédric Le Goater
On 3/7/24 10:53, Vladimir Sementsov-Ogievskiy wrote: On 06.03.24 16:34, Cédric Le Goater wrote: The purpose is to record a potential error in the migration stream if qemu_savevm_state_setup() fails. Most of the current .save_setup() handlers can be modified to use the Error argument instead of m

Re: [PATCH v7 4/9] qemu-options.hx: Document the virtio-iommu-pci granule option

2024-03-07 Thread Eric Auger
On 3/7/24 11:21, Philippe Mathieu-Daudé wrote: > On 7/3/24 08:32, Eric Auger wrote: >> Hi Philippe, >> >> On 3/6/24 21:44, Philippe Mathieu-Daudé wrote: >>> On 6/3/24 21:32, Eric Auger wrote: We are missing an entry for the virtio-iommu-pci device. Add the information on which machine

Re: [PATCH v2 0/9] Add AST2700 support

2024-03-07 Thread Cédric Le Goater
On 3/5/24 04:38, Jamin Lin wrote: -Original Message- From: Cédric Le Goater Sent: Monday, March 4, 2024 11:54 PM To: Jamin Lin ; Peter Maydell ; Andrew Jeffery ; Joel Stanley ; Alistair Francis ; open list:ASPEED BMCs ; open list:All patches CC here Cc: Troy Lee ; Yunlin Tang Subject:

Re: QEMU Compatibility for Cortex-A55 AArch32 Firmware

2024-03-07 Thread Peter Maydell
On Thu, 7 Mar 2024 at 01:03, yb liu wrote: > > Thanks a lot for you respond me soon! > The exact instruction is mrc, and the exception happended in early boot > process. I have no idea to how to debug this error because it happended in > code_gen_prologue. That's a system register access. If yo

[PATCH] target/ppc: Move floating-point arithmetic instructions to decodetree.

2024-03-07 Thread Chinmay Rath
This patch moves the below instructions to decodetree specification : f{add, sub, mul, div, re, rsqrte, madd, msub, nmadd, nmsub}[s][.] : A-form ft{div, sqrt} : X-form With this patch, all the floating-point arithmetic instructions have

Re: [PATCH v1 0/8] virtio, vhost: Add VIRTIO_F_NOTIFICATION_DATA support

2024-03-07 Thread Eugenio Perez Martin
On Wed, Mar 6, 2024 at 8:34 AM Michael S. Tsirkin wrote: > > On Wed, Mar 06, 2024 at 08:07:31AM +0100, Eugenio Perez Martin wrote: > > On Wed, Mar 6, 2024 at 6:34 AM Jason Wang wrote: > > > > > > On Tue, Mar 5, 2024 at 3:46 AM Jonah Palmer > > > wrote: > > > > > > > > The goal of these patches

Re: [PATCH v5 30/65] i386/tdx: Support user configurable mrconfigid/mrowner/mrownerconfig

2024-03-07 Thread Xiaoyao Li
On 3/7/2024 4:39 PM, Markus Armbruster wrote: Xiaoyao Li writes: On 2/29/2024 9:25 PM, Markus Armbruster wrote: Xiaoyao Li writes: On 2/29/2024 4:37 PM, Markus Armbruster wrote: Xiaoyao Li writes: From: Isaku Yamahata Three sha384 hash values, mrconfigid, mrowner and mrownerconfig, o

Re: [PATCH v5 49/65] i386/tdx: handle TDG.VP.VMCALL

2024-03-07 Thread Xiaoyao Li
On 2/29/2024 9:28 PM, Markus Armbruster wrote: Xiaoyao Li writes: On 2/29/2024 4:40 PM, Markus Armbruster wrote: Xiaoyao Li writes: From: Isaku Yamahata Add property "quote-generation-socket" to tdx-guest, which is a property of type SocketAddress to specify Quote Generation Service(QGS)

Re: [PATCH v5 52/65] i386/tdx: Wire TDX_REPORT_FATAL_ERROR with GuestPanic facility

2024-03-07 Thread Xiaoyao Li
On 2/29/2024 4:51 PM, Markus Armbruster wrote: Xiaoyao Li writes: Integrate TDX's TDX_REPORT_FATAL_ERROR into QEMU GuestPanic facility Originated-from: Isaku Yamahata Signed-off-by: Xiaoyao Li --- Changes in v5: - mention additional error information in gpa when it presents; - refine the do

Re: [PATCH v4 11/25] migration: Add Error** argument to .save_setup() handler

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 07.03.24 13:31, Cédric Le Goater wrote: On 3/7/24 10:53, Vladimir Sementsov-Ogievskiy wrote: On 06.03.24 16:34, Cédric Le Goater wrote: The purpose is to record a potential error in the migration stream if qemu_savevm_state_setup() fails. Most of the current .save_setup() handlers can be mod

Re: [PATCH v2 5/6] qapi: device-sync-config: check runstate

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 07.03.24 12:57, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: Command result is racy if allow it during migration. Let's allow the sync only in RUNNING state. Signed-off-by: Vladimir Sementsov-Ogievskiy If I understand this correctly, the previous commit introduces a rac

Re: [PATCH v2 6/6] qapi: introduce CONFIG_READ event

2024-03-07 Thread Vladimir Sementsov-Ogievskiy
On 07.03.24 13:01, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: Send a new event when guest reads virtio-pci config after virtio_notify_config() call. That's useful to check that guest fetched modified config, for example after resizing disk backend. Signed-off-by: Vladimir

Re: [PULL for 9.0 00/29] maintainer updates (tests, gdbstub, plugins)

2024-03-07 Thread Peter Maydell
On Wed, 6 Mar 2024 at 14:42, Alex Bennée wrote: > > The following changes since commit db596ae19040574e41d086e78469014191d7d7fc: > > Merge tag 'pull-target-arm-20240305' of > https://git.linaro.org/people/pmaydell/qemu-arm into staging (2024-03-05 > 13:54:54 +) > > are available in the Git

Re: [PATCH-for-9.0 1/9] hw/xen/hvm: Inline TARGET_PAGE_ALIGN() macro

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: Use TARGET_PAGE_SIZE to calculate TARGET_PAGE_ALIGN. Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/xen/xen-hvm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/i386/xen/xen-hvm.c b/hw/i386/xen/xen-hvm.c index f

Re: [PATCH v2] migration/multifd: Don't fsync when closing QIOChannelFile

2024-03-07 Thread Fabiano Rosas
Peter Xu writes: > On Tue, Mar 05, 2024 at 04:56:29PM -0300, Fabiano Rosas wrote: >> Commit bc38feddeb ("io: fsync before closing a file channel") added a >> fsync/fdatasync at the closing point of the QIOChannelFile to ensure >> integrity of the migration stream in case of QEMU crash. >> >> The

[PATCH] linux-aio: add IO_CMD_FDSYNC command support

2024-03-07 Thread Prasad Pandit
From: Prasad Pandit Libaio defines IO_CMD_FDSYNC command to sync all outstanding asynchronous I/O operations, by flushing out file data to the disk storage. Enable linux-aio to submit such aio request. This helps to reduce latency induced via pthread_create calls by thread-pool (aio=threads). S

Re: [PATCH-for-9.0 2/9] hw/xen/hvm: Propagate page_mask to a pair of functions

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: We are going to replace TARGET_PAGE_MASK by a runtime variable. In order to reduce code duplication, propagate TARGET_PAGE_MASK to get_physmapping() and xen_phys_offset_to_gaddr(). Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/xen/xe

Re: [PATCH-for-9.0 3/9] hw/xen/hvm: Get target page size at runtime

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: In order to build this file once for all targets, replace: TARGET_PAGE_BITS -> qemu_target_page_bits() TARGET_PAGE_SIZE -> qemu_target_page_size() TARGET_PAGE_MASK -> -qemu_target_page_size() Signed-off-by: Philippe Mathieu-Daudé ---

Re: [PATCH-for-9.0 4/9] hw/xen/hvm: Expose xen_memory_listener declaration

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: There can only be a single xen_memory_listener definition in a qemu-system binary. Signed-off-by: Philippe Mathieu-Daudé --- include/hw/xen/xen-hvm-common.h | 1 + hw/arm/xen_arm.c| 2 +- hw/i386/xen/xen-hvm.c | 2

Re: [PATCH-for-9.0 5/9] hw/xen/hvm: Expose xen_read_physmap() prototype

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: In a pair of commit we are going to call xen_read_physmap() out of hw/i386/xen/xen-hvm.c. Signed-off-by: Philippe Mathieu-Daudé --- include/hw/xen/xen-hvm-common.h | 1 + hw/i386/xen/xen-hvm.c | 4 ++-- 2 files changed, 3 inserti

Re: [RFC PATCH-for-9.0 6/9] hw/xen/hvm: Initialize xen_physmap QLIST in xen_read_physmap()

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: xen_read_physmap() is the first function requiring xen_physmap QLIST being initialized. Move the init call there. Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/xen/xen-hvm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) di

Re: [PATCH-for-9.0 7/9] hw/xen/hvm: Extract common code to xen-hvm-common.c

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: Extract non-x86 specific code out of xen-hvm.c, to xen-hvm-common.c. For now this new file is only build for x86 targets. s/build/built Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/xen/xen-hvm-common.c | 473

[PATCH v2 2/5] docs/interop/firmware.json: Fix doc for FirmwareFlashMode

2024-03-07 Thread Thomas Weißschuh
The doc title did not match the actual definition. Fixes: 2720ceda05 ("docs: expand firmware descriptor to allow flash without NVRAM") Signed-off-by: Thomas Weißschuh Reviewed-by: Philippe Mathieu-Daudé --- docs/interop/firmware.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[PATCH v2 1/5] docs/interop/firmware.json: Align examples

2024-03-07 Thread Thomas Weißschuh
The QAPI generator now validates the alignment and rejects this file. Signed-off-by: Thomas Weißschuh --- docs/interop/firmware.json | 384 ++--- 1 file changed, 192 insertions(+), 192 deletions(-) diff --git a/docs/interop/firmware.json b/docs/interop/fi

[PATCH v2 3/5] docs/interop/firmware.json: Use full include paths

2024-03-07 Thread Thomas Weißschuh
The included files are part of the toplevel QAPI directory and need to be included from there. Signed-off-by: Thomas Weißschuh --- docs/interop/firmware.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/interop/firmware.json b/docs/interop/firmware.json index 54a1

[PATCH v2 5/5] docs: add test for firmware.json QAPI

2024-03-07 Thread Thomas Weißschuh
To make sure that the QAPI description stays valid add a testcase. Suggested-by: Philippe Mathieu-Daudé Link: https://lore.kernel.org/qemu-devel/d9ce0234-4beb-4b90-b14c-76810d3b8...@linaro.org/ Signed-off-by: Thomas Weißschuh --- docs/meson.build | 5 + 1 file changed, 5 insertions(+) dif

[PATCH v2 4/5] docs/interop/firmware.json: Include pragma.json

2024-03-07 Thread Thomas Weißschuh
The files included by firmware.json use names that do not satisfy the generators requirements. By including pragma.json these errors are suppressed. Signed-off-by: Thomas Weißschuh --- docs/interop/firmware.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/interop/firmware.json b/d

[PATCH v2 0/5] docs/interop/firmware.json: scripts/qapi-gen.py compatibility

2024-03-07 Thread Thomas Weißschuh
docs/interop/firmware.json is currently not usable with qapi-gen.py due to various non-functional issues. Fix those issue to provide compatibility. Signed-off-by: Thomas Weißschuh --- Changes in v2: - Add review tag from Philippe - Add Fixes tag (Philippe) - Add testcase (Philippe) - Link to v1:

Re: [PATCH v4 16/25] vfio: Add Error** argument to .set_dirty_page_tracking() handler

2024-03-07 Thread Cédric Le Goater
On 3/7/24 09:09, Eric Auger wrote: Hi Cédric, On 3/6/24 14:34, Cédric Le Goater wrote: We will use the Error object to improve error reporting in the .log_global*() handlers of VFIO. Add documentation while at it. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Cédric Le Goater --- Cha

Re: [RFC PATCH-for-9.0 8/9] hw/xen/hvm: Merge xen-hvm-common.c files

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: hw/i386/xen/xen-hvm-common.c content is target agnostic, and should be common to all targets. Merge both files. Remove the now unnecessary xen_register_framebuffer() stub. ARM targets now inherit the common xen_memory_listener. Signed-of

Re: [PATCH-for-9.0 9/9] hw/xen/hvm: Inline xen_arch_set_memory()

2024-03-07 Thread Manos Pitsidianakis
On Tue, 14 Nov 2023 18:31, Philippe Mathieu-Daudé wrote: xen_arch_set_memory() is not arch-specific anymore. Being called once, inline it in xen_set_memory(). Signed-off-by: Philippe Mathieu-Daudé --- include/hw/xen/xen-hvm-common.h | 3 - hw/xen/xen-hvm-common.c | 104 +++

Re: [PATCH v5 06/13] hw/mem/cxl_type3: Add host backend and address space handling for DC regions

2024-03-07 Thread Jonathan Cameron via
> > > @@ -868,16 +974,24 @@ static int cxl_type3_hpa_to_as_and_dpa(CXLType3Dev > > > *ct3d, > > > AddressSpace **as, > > > uint64_t *dpa_offset) > > > { > > > -MemoryRegion *vmr = NULL, *pmr = NULL; > > > +Mem

Re: [RISC-V][tech-server-platform] [RISC-V][tech-server-soc] [RFC 2/2] target/riscv: Add server platform reference cpu

2024-03-07 Thread Heinrich Schuchardt
On 07.03.24 08:36, Wu, Fei2 wrote: On 3/6/2024 9:26 PM, Wu, Fei wrote: On 3/5/2024 1:58 PM, Wu, Fei wrote: On 3/5/2024 3:43 AM, Daniel Henrique Barboza wrote: On 3/4/24 07:25, Fei Wu wrote: The harts requirements of RISC-V server platform [1] require RVA23 ISA profile support, plus Sv48, Sv

Re: [PATCH v5 08/13] hw/cxl/cxl-mailbox-utils: Add mailbox commands to support add/release dynamic capacity response

2024-03-07 Thread Jonathan Cameron via
On Wed, 6 Mar 2024 13:39:50 -0800 fan wrote: > > > +} > > > +if (len2) { > > > +cxl_insert_extent_to_extent_list(extent_list, > > > dpa + len, > > > + len2, NULL, 0); > > > +

Re: [PATCH v3 4/7] Add migrate_set_ports into migrate_qmp to change migration port number

2024-03-07 Thread Fabiano Rosas
Het Gala writes: > On 06/03/24 9:31 pm, Fabiano Rosas wrote: >> Het Gala writes: >> >>> On 06/03/24 8:06 pm, Fabiano Rosas wrote: Het Gala writes: > Add a migrate_set_ports() function that from each QDict, fills in > the port in case it was 0 in the test. > Handle a list

Re: [PATCH v5 08/13] hw/cxl/cxl-mailbox-utils: Add mailbox commands to support add/release dynamic capacity response

2024-03-07 Thread Jonathan Cameron via
> > > +static void cxl_destroy_dc_regions(CXLType3Dev *ct3d) > > > +{ > > > +CXLDCExtent *ent; > > > + > > > +while (!QTAILQ_EMPTY(&ct3d->dc.extents)) { > > > +ent = QTAILQ_FIRST(&ct3d->dc.extents); > > > +cxl_remove_extent_from_extent_list(&ct3d->dc.extents, ent); > > >

Re: [PATCH v4 08/25] migration: Always report an error in ram_save_setup()

2024-03-07 Thread Fabiano Rosas
Cédric Le Goater writes: > This will prepare ground for future changes adding an Error** argument > to the save_setup() handler. We need to make sure that on failure, > ram_save_setup() sets a new error. > > Signed-off-by: Cédric Le Goater Reviewed-by: Fabiano Rosas

Re: [PATCH v5 09/13] hw/cxl/events: Add qmp interfaces to add/release dynamic capacity extents

2024-03-07 Thread Jonathan Cameron via
... > > > +list = records; > > > +extents = g_new0(CXLDCExtentRaw, num_extents); > > > +while (list) { > > > +CXLDCExtent *ent; > > > +bool skip_extent = false; > > > + > > > +offset = list->value->offset; > > > +len = list->value->len; > > > + > > > +

  1   2   3   4   >