Re: [RFC PATCH 0/3] TDX attestation support

2025-06-19 Thread Xiaoyao Li
On 6/20/2025 4:33 AM, Paolo Bonzini wrote: This is my update of Binbin's patches from https://github.com/intel-staging/qemu-tdx/commits/binbinwu/GetTdVmCallInfo_fixup/, updated for the proposed userspace API at https://lore.kernel.org/kvm/20250619180159.187358-1-pbonz...@redhat.com/T/ and with a

Re: [PATCH v4 4/8] hw/arm/virt-acpi-build: Fix comment in build_iort

2025-06-19 Thread Eric Auger
Hi Gustavo, On 6/19/25 7:07 PM, Gustavo Romero wrote: > Hi Eric, > > On 6/17/25 10:22, Eric Auger wrote: >> Hi Gustavo, >> >> On 6/16/25 3:18 PM, Gustavo Romero wrote: >>> The comment about the mapping from SMMU to ITS is incorrect and it >>> reads >>> "RC -> ITS". The code in question actually ma

Re: [PATCH 3/3] i386/tdx: handle TDG.VP.VMCALL

2025-06-19 Thread Xiaoyao Li
On 6/20/2025 4:33 AM, Paolo Bonzini wrote: ... +static void tdx_generate_quote_cleanup(TdxGenerateQuoteTask *task) +{ +timer_del(&task->timer); + +g_source_remove(task->watch); It needs to be if (task->watch) { g_source_remove(task->watch); } for the

Re: [PULL 12/17] virtio-gpu: support context init multiple timeline

2025-06-19 Thread Alex Bennée
Yiwei Zhang writes: > On Sun, Jun 8, 2025 at 1:24 AM Akihiko Odaki > wrote: >> >> On 2025/06/06 1:26, Alex Bennée wrote: >> > From: Yiwei Zhang >> > >> > Venus and later native contexts have their own fence context along with >> > multiple timelines within. Fences wtih VIRTIO_GPU_FLAG_INFO_RING

[PATCH 0/2] Memory and PCI definitions for emulated ATS

2025-06-19 Thread CLEMENT MATHIEU--DRIF
This short series adds the 'address type' bit (concept from PCIe) to the memory attributes and extends the IOMMUAccessFlags enum. This will be required to implement ATS support for the virtual IOMMUs. Address type: Field present in the PCIe R/W requests, it allows devices to tell the IOMMU if the

[PATCH 2/2] memory: Add permissions in IOMMUAccessFlags

2025-06-19 Thread CLEMENT MATHIEU--DRIF
This will be necessary for devices implementing ATS. We also define a new macro IOMMU_ACCESS_FLAG_FULL in addition to IOMMU_ACCESS_FLAG to support more access flags. IOMMU_ACCESS_FLAG is kept for convenience and backward compatibility. Here are the flags added (defined by the PCIe 5 specification)

[PATCH 1/2] pci: Add a memory attribute for pre-translated DMA operations

2025-06-19 Thread CLEMENT MATHIEU--DRIF
The address_type bit will be set to PCI_AT_TRANSLATED by devices that use cached addresses obtained via ATS. Signed-off-by: Clement Mathieu--Drif --- include/exec/memattrs.h | 3 +++ include/hw/pci/pci.h| 9 + 2 files changed, 12 insertions(+) diff --git a/include/exec/memattrs.h b/

RE: [PATCH V5 00/38] Live update: vfio and iommufd

2025-06-19 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Cédric Le Goater >Subject: Re: [PATCH V5 00/38] Live update: vfio and iommufd > >Zhenzhong, Eric, > >On 6/12/25 09:23, Cédric Le Goater wrote: >> On 6/11/25 16:39, Steven Sistare wrote: >>> On 6/11/2025 10:25 AM, Cédric Le Goater wrote: On 6/10/2

Re: [RFC v5 0/4] Add QEMU model for ASPEED OTP memory and integrate with SoCs

2025-06-19 Thread Cédric Le Goater
Hello Kane, On 6/19/25 08:41, Kane Chen wrote: From: Kane-Chen-AS This patch series introduces a QEMU model for the ASPEED OTP (One-Time Programmable) memory, along with its integration into the Secure Boot Controller (SBC) and supported SoCs (AST2600, AST1030). The OTP model emulates a simpl

Re: [PATCH v7 3/5] memory: Unify the definiton of ReplayRamPopulate() and ReplayRamDiscard()

2025-06-19 Thread Chenyi Qiang
On 6/19/2025 10:29 PM, Peter Xu wrote: > On Thu, Jun 19, 2025 at 11:06:46AM +0800, Chenyi Qiang wrote: >> To fix the build error with --enable-docs configuration, Add the below fixup > > Thanks, this works for me. > > Though I just noticed it has more than the doc issue.. please see: > > http

[PATCH v2] hw/riscv/virt: Add acpi ged and powerdown support

2025-06-19 Thread liu.xuemei1
From: Xuemei Liu This adds powerdown support by implementing the ACPI GED. Signed-off-by: Xuemei Liu Co-authored-by: Björn Töpel --- Changes in v2: - Unwrappered acpi_dsdt_add_ged function - Modified base address of VIRT_ACPI_GED - Added conditions for function calls - Adjusted code formattin

Re: [PULL 00/14] loongarch-to-apply queue

2025-06-19 Thread gaosong
在 2025/6/20 上午4:39, Stefan Hajnoczi 写道: gpg:using RSA key CA473C44D6A09C189A193FCD452B96852B268216 gpg: Can't check signature: No public key Why has the GPG key changed? Your previous pull request was signed with key B8FF1DA0D2FDCB2DA09C6C2C40A2FFF239263EDF. If you would like to

Re: [PATCH v7 4/5] ram-block-attributes: Introduce RamBlockAttributes to manage RAMBlock with guest_memfd

2025-06-19 Thread Chenyi Qiang
On 6/12/2025 4:27 PM, Chenyi Qiang wrote: > Commit 852f0048f3 ("RAMBlock: make guest_memfd require uncoordinated > discard") highlighted that subsystems like VFIO may disable RAM block > discard. However, guest_memfd relies on discard operations for page > conversion between private and shared m

Re: [PULL 12/17] virtio-gpu: support context init multiple timeline

2025-06-19 Thread Yiwei Zhang
On Sun, Jun 8, 2025 at 1:24 AM Akihiko Odaki wrote: > > On 2025/06/06 1:26, Alex Bennée wrote: > > From: Yiwei Zhang > > > > Venus and later native contexts have their own fence context along with > > multiple timelines within. Fences wtih VIRTIO_GPU_FLAG_INFO_RING_IDX in > > the flags must be di

Re: [PULL 00/14] loongarch-to-apply queue

2025-06-19 Thread gaosong
available in the Git repository at: https://github.com/gaosong715/qemu.git tags/pull-loongarch-20250619 From https://github.com/gaosong715/qemu * tag pull-loongarch-20250619 -> FETCH_HEAD gpg: Signature made Thu 19 Jun 2025 04:49:38 EDT gpg:

RE: [PATCH v4] hw/misc/aspeed_scu: Handle AST2600 protection key registers correctly

2025-06-19 Thread Jamin Lin
> Subject: Re: [PATCH v4] hw/misc/aspeed_scu: Handle AST2600 protection key > registers correctly > > Jamin, > > On 6/19/25 10:53, Tan Siewert wrote: > > The AST2600 SCU has two protection key registers (0x00 and 0x10) that > > both need to be unlocked. (Un-)locking 0x00 modifies both protection

[PATCH v2 02/12] aio-posix: keep polling enabled with fdmon-io_uring.c

2025-06-19 Thread Stefan Hajnoczi
Commit 816a430c517e ("util/aio: Defer disabling poll mode as long as possible") kept polling enabled when the event loop timeout is 0. Since there is no timeout the event loop will continue immediately and the overhead of disabling and re-enabling polling can be avoided. fdmon-io_uring.c is unable

[PATCH v2 03/12] tests/unit: skip test-nested-aio-poll with io_uring

2025-06-19 Thread Stefan Hajnoczi
test-nested-aio-poll relies on internal details of how fdmon-poll.c handles AioContext polling. Skip it when other fdmon implementations are in use. Note that this test is only built on POSIX systems so it is safe to include "util/aio-posix.h". Signed-off-by: Stefan Hajnoczi Reviewed-by: Eric Bl

[PATCH v2 09/12] aio-posix: add aio_add_sqe() API for user-defined io_uring requests

2025-06-19 Thread Stefan Hajnoczi
Introduce the aio_add_sqe() API for submitting io_uring requests in the current AioContext. This allows other components in QEMU, like the block layer, to take advantage of io_uring features without creating their own io_uring context. This API supports nested event loops just like file descriptor

[PATCH v2 08/12] aio-posix: gracefully handle io_uring_queue_init() failure

2025-06-19 Thread Stefan Hajnoczi
io_uring may not be available at runtime due to system policies (e.g. the io_uring_disabled sysctl) or creation could fail due to file descriptor resource limits. Handle failure scenarios as follows: If another AioContext already has io_uring, then fail AioContext creation so that the aio_add_sqe

[PATCH v2 01/12] aio-posix: fix race between io_uring CQE and AioHandler deletion

2025-06-19 Thread Stefan Hajnoczi
When an AioHandler is enqueued on ctx->submit_list for removal, the fill_sq_ring() function will submit an io_uring POLL_REMOVE operation to cancel the in-flight POLL_ADD operation. There is a race when another thread enqueues an AioHandler for deletion on ctx->submit_list when the POLL_ADD CQE ha

[PATCH v2 11/12] block/io_uring: use aio_add_sqe()

2025-06-19 Thread Stefan Hajnoczi
AioContext has its own io_uring instance for file descriptor monitoring. The disk I/O io_uring code was developed separately. Originally I thought the characteristics of file descriptor monitoring and disk I/O were too different, requiring separate io_uring instances. Now it has become clear to me

[PATCH v2 07/12] aio: add errp argument to aio_context_setup()

2025-06-19 Thread Stefan Hajnoczi
When aio_context_new() -> aio_context_setup() fails at startup it doesn't really matter whether errors are returned to the caller or the process terminates immediately. However, it is not acceptable to terminate when hotplugging --object iothread at runtime. Refactor aio_context_setup() so that er

[PATCH v2 12/12] block/io_uring: use non-vectored read/write when possible

2025-06-19 Thread Stefan Hajnoczi
The io_uring_prep_readv2/writev2() man pages recommend using the non-vectored read/write operations when possible for performance reasons. I didn't measure a significant difference but it doesn't hurt to have this optimization in place. Suggested-by: Eric Blake Signed-off-by: Stefan Hajnoczi --

[PATCH v2 00/12] aio: add the aio_add_sqe() io_uring API

2025-06-19 Thread Stefan Hajnoczi
v2: - Performance improvements - Fix pre_sqe -> prep_sqe typo [Eric] - Add #endif terminator comment [Eric] - Fix spacing in aio_ctx_finalize() argument list [Eric] - Add new "block/io_uring: use non-vectored read/write when possible" patch [Eric] - Drop Patch 1 because multi-shot POLL_ADD has edg

[PATCH v2 05/12] aio: remove aio_context_use_g_source()

2025-06-19 Thread Stefan Hajnoczi
There is no need for aio_context_use_g_source() now that epoll(7) and io_uring(7) file descriptor monitoring works with the glib event loop. AioContext doesn't need to be notified that GSource is being used. Signed-off-by: Stefan Hajnoczi Reviewed-by: Eric Blake --- include/block/aio.h

[PATCH v2 04/12] aio-posix: integrate fdmon into glib event loop

2025-06-19 Thread Stefan Hajnoczi
AioContext's glib integration only supports ppoll(2) file descriptor monitoring. epoll(7) and io_uring(7) disable themselves and switch back to ppoll(2) when the glib event loop is used. The main loop thread cannot use epoll(7) or io_uring(7) because it always uses the glib event loop. Future QEMU

[PATCH v2 10/12] aio-posix: avoid EventNotifier for cqe_handler_bh

2025-06-19 Thread Stefan Hajnoczi
fdmon_ops->wait() is called with notify_me enabled. This makes it an expensive place to call qemu_bh_schedule() because aio_notify() invokes write(2) on the EventNotifier. Moving qemu_bh_schedule() after notify_me is reset improves IOPS from 270k to 300k IOPS with --blockdev file,aio=io_uring. I

[PATCH v2 06/12] aio: free AioContext when aio_context_new() fails

2025-06-19 Thread Stefan Hajnoczi
g_source_destroy() only removes the GSource from the GMainContext it's attached to, if any. It does not free it. Use g_source_unref() instead so that the AioContext (which embeds a GSource) is freed. There is no need to call g_source_destroy() in aio_context_new() because the GSource isn't attache

Re: [PATCH 07/20] accel/hvf: Trace VM memory mapping

2025-06-19 Thread Philippe Mathieu-Daudé
On 19/6/25 15:13, Philippe Mathieu-Daudé wrote: Trace memory mapped / unmapped in the guest. Signed-off-by: Philippe Mathieu-Daudé --- meson.build | 1 + accel/hvf/trace.h | 2 ++ accel/hvf/hvf-accel-ops.c | 6 ++ accel/hvf/trace-events| 7 +++ 4 files ch

Re: [PATCH 19/20] hw/arm/sbsa-ref: Tidy up use of RAMLIMIT_GB definition

2025-06-19 Thread Philippe Mathieu-Daudé
On 19/6/25 23:28, Richard Henderson wrote: On 6/19/25 14:20, Philippe Mathieu-Daudé wrote: @@ -756,7 +756,9 @@ static void sbsa_ref_init(MachineState *machine)   sms->smp_cpus = smp_cpus;   if (machine->ram_size > sbsa_ref_memmap[SBSA_MEM].size) { -    error_report("sbsa-ref: cannot

Re: [PATCH 19/20] hw/arm/sbsa-ref: Tidy up use of RAMLIMIT_GB definition

2025-06-19 Thread Richard Henderson
On 6/19/25 14:20, Philippe Mathieu-Daudé wrote: @@ -756,7 +756,9 @@ static void sbsa_ref_init(MachineState *machine)   sms->smp_cpus = smp_cpus;   if (machine->ram_size > sbsa_ref_memmap[SBSA_MEM].size) { -    error_report("sbsa-ref: cannot model more than %dGB RAM", RAMLIMIT_GB); +  

Re: [PATCH 06/20] target/arm/hvf: Trace hv_vcpu_run() failures

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Allow distinguishing HV_ILLEGAL_GUEST_STATE in trace events. Signed-off-by: Philippe Mathieu-Daudé --- target/arm/hvf/hvf.c| 10 +- target/arm/hvf/trace-events | 1 + 2 files changed, 10 insertions(+), 1 deletion(-) Reviewed-

Re: [PATCH 16/20] hw/arm/virt: Only require TCG || QTest to use TrustZone

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: We only need TCG (or QTest) to use TrustZone, whether KVM or HVF are used is not relevant. Reported-by: Alex Bennée Signed-off-by: Philippe Mathieu-Daudé --- hw/arm/virt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Rich

Re: [PATCH 15/20] target/arm/hvf: Really set Generic Timer counter frequency

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Setting ARMCPU::gt_cntfrq_hz in hvf_arch_init_vcpu() is not correct because the timers have already be initialized with the default frequency. Set it earlier in the AccelOpsClass::cpu_target_realize() handler instead, and assert the value is correc

Re: [PATCH 1/2] block/rbd: support selected key-value-pairs via QAPI

2025-06-19 Thread Ilya Dryomov
On Thu, Jun 19, 2025 at 8:38 PM Ilya Dryomov wrote: > > On Mon, Jun 16, 2025 at 2:38 PM Fiona Ebner wrote: > > > > Am 16.06.25 um 12:28 schrieb Ilya Dryomov: > > > On Mon, Jun 16, 2025 at 11:52 AM Daniel P. Berrangé > > > wrote: > > >> On Mon, Jun 16, 2025 at 11:25:54AM +0200, Ilya Dryomov wrot

Re: [PATCH 19/20] hw/arm/sbsa-ref: Tidy up use of RAMLIMIT_GB definition

2025-06-19 Thread Philippe Mathieu-Daudé
On 19/6/25 23:09, Richard Henderson wrote: On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Define RAMLIMIT_BYTES using the TiB definition and display the error parsed with size_to_str():    $ qemu-system-aarch64-unsigned -M sbsa-ref -m 9T    qemu-system-aarch64-unsigned: sbsa-ref: cannot model

Re: [PATCH 10/20] target/arm: Restrict system register properties to system binary

2025-06-19 Thread Philippe Mathieu-Daudé
On 19/6/25 15:13, Philippe Mathieu-Daudé wrote: Do not expose system-specific properties on user-mode binaries. Signed-off-by: Philippe Mathieu-Daudé --- target/arm/cpu.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/target/arm/cpu.c b/target/arm/cpu.c index eb0639de

Re: [PATCH 09/20] target/arm/hvf: Correct dtb_compatible value

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Linux kernel knows how to parse "arm,armv8", not "arm,arm-v8". Fixes: 585df85efea ("hvf: arm: Implement -cpu host") Signed-off-by: Philippe Mathieu-Daudé --- target/arm/hvf/hvf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH 08/20] target/arm/hvf: Log $pc in hvf_unknown_hvc() trace event

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Tracing $PC for unknown HVC instructions to not have to look at the disassembled flow of instructions. Signed-off-by: Philippe Mathieu-Daudé --- target/arm/hvf/hvf.c| 4 ++-- target/arm/hvf/trace-events | 2 +- 2 files changed, 3 insert

Re: [PATCH 03/20] target/arm: Unify gen_exception_internal()

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Same code, use the generic variant. Signed-off-by: Philippe Mathieu-Daudé --- target/arm/tcg/translate.h | 1 + target/arm/tcg/translate-a64.c | 6 -- target/arm/tcg/translate.c | 2 +- 3 files changed, 2 insertions(+), 7 deletions

Re: [PATCH 01/20] target/arm: Remove arm_handle_psci_call() stub

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Since commit 0c1aaa66c24 ("target/arm: wrap psci call with tcg_enabled") the arm_handle_psci_call() call is elided when TCG is disabled. Signed-off-by: Philippe Mathieu-Daudé --- target/arm/internals.h | 6 +- 1 file changed, 1 insertion(+)

Re: [PATCH 02/20] target/arm: Reduce arm_cpu_post_init() declaration scope

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: arm_cpu_post_init() is only used within the same file unit. Signed-off-by: Philippe Mathieu-Daudé --- target/arm/cpu.h | 2 -- target/arm/cpu.c | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) Reviewed-by: Richard Henderson r~

Re: [PATCH 19/20] hw/arm/sbsa-ref: Tidy up use of RAMLIMIT_GB definition

2025-06-19 Thread Richard Henderson
On 6/19/25 06:13, Philippe Mathieu-Daudé wrote: Define RAMLIMIT_BYTES using the TiB definition and display the error parsed with size_to_str(): $ qemu-system-aarch64-unsigned -M sbsa-ref -m 9T qemu-system-aarch64-unsigned: sbsa-ref: cannot model more than 8 TiB of RAM Signed-off-by: Phili

Re: [PATCH v2 01/12] hw/i386/pc_piix.c: duplicate pc_init1() into pc_isa_init()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: This is to prepare for splitting the isapc machine into its own separate file. Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 260 +- 1 file changed, 259 insertions(+), 1 deletion(-) Reviewed-by:

Re: [PATCH v2 02/12] hw/i386/pc_piix.c: remove pcmc->pci_enabled dependent initialisation from pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: This code will never be used for an isapc machine. s/This/PCI/ Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 105 -- 1 file changed, 8 insertions(+), 97 d

Re: [PATCH v2 03/12] hw/i386/pc_piix.c: remove SMI and piix4_pm initialisation from pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: These are based upon the PIIX4 PCI chipset and so can never be used on an isapc machine. Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 19 --- 1 file changed, 19 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH v2 05/12] hw/i386/pc_piix.c: remove nvdimm initialisation from pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: NVDIMMs cannot be used by PCs from a pre-PCI era. Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 6 -- 1 file changed, 6 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH v2 06/12] hw/i386/pc_piix.c: simplify RAM size logic in pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: All isapc machines must have 32-bit CPUs and so the RAM split logic can be hardcoded accordingly. s/32-bit CPUs/32-bit address space/? Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 58 --- 1

Re: [PATCH v2 12/12] hw/i386: move isapc machine to separate isapc.c file

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: Now that pc_init_isa() is independent of any PCI initialisation, move it into a separate isapc.c file. This enables us to finally fix the dependency of ISAPC on I440FX in hw/i386/Kconfig. Note that as part of the move to a separate file we can see that t

Re: [PATCH v2 07/12] hw/i386/pc_piix.c: hardcode hole64_size to 0 in pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: All isapc machines must have 32-bit CPUs and have no PCI 64-bit hole so it can be hardcoded to 0. Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH v2 09/12] hw/i386/pc_piix.c: always initialise ISA IDE drives in pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: By definition an isapc machine must always use ISA IDE drives ISA: yes, IDE: not necessarily. Anyhow, Reviewed-by: Philippe Mathieu-Daudé so ensure that they are always enabled. At the same time also remove the surrounding CONFIG_IDE_ISA define sinc

Re: [PATCH v2 10/12] hw/i386/pc_piix.c: assume pcmc->pci_enabled is always false in pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: By definition PCI can never be enabled on an isapc machine so hardcode the relevant values set via pcmc->pci_enabled. Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Reviewed-by: Phil

Re: [PATCH v2 11/12] hw/i386/pc_piix.c: hardcode pcms->pci_bus to NULL in pc_init_isa()

2025-06-19 Thread Philippe Mathieu-Daudé
On 18/6/25 13:27, Mark Cave-Ayland wrote: By definition PCI can never be enabled on an isapc machine so hardcode the PCIBus argument of pc_nic_init() to NULL. Signed-off-by: Mark Cave-Ayland --- hw/i386/pc_piix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Philippe

Re: [PULL 00/14] loongarch-to-apply queue

2025-06-19 Thread Stefan Hajnoczi
ilable in the Git repository at: > > https://github.com/gaosong715/qemu.git tags/pull-loongarch-20250619 >From https://github.com/gaosong715/qemu * tag pull-loongarch-20250619 -> FETCH_HEAD gpg: Signature made Thu 19 Jun 2025 04:49:38 EDT gpg:using RSA k

[PATCH 3/3] i386/tdx: handle TDG.VP.VMCALL

2025-06-19 Thread Paolo Bonzini
From: Isaku Yamahata Add property "quote-generation-socket" to tdx-guest, which is a property of type SocketAddress to specify Quote Generation Service(QGS). On request of GetQuote, it connects to the QGS socket, read request data from shared guest memory, send the request data to the QGS, and s

[RFC PATCH 0/3] TDX attestation support

2025-06-19 Thread Paolo Bonzini
This is my update of Binbin's patches from https://github.com/intel-staging/qemu-tdx/commits/binbinwu/GetTdVmCallInfo_fixup/, updated for the proposed userspace API at https://lore.kernel.org/kvm/20250619180159.187358-1-pbonz...@redhat.com/T/ and with a few tweaks to drop the remains of the quote g

[PATCH 1/3] update Linux headers to v6.16-rc3

2025-06-19 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- include/standard-headers/asm-x86/setup_data.h | 13 +- include/standard-headers/drm/drm_fourcc.h | 45 +++ include/standard-headers/linux/ethtool.h | 124 +- include/standard-headers/linux/fuse.h | 6 +- .../linux/input-eve

[PATCH 2/3] i386/tdx: handle TDG.VP.VMCALL

2025-06-19 Thread Paolo Bonzini
From: Binbin Wu Signed-off-by: Binbin Wu Signed-off-by: Paolo Bonzini --- target/i386/kvm/tdx.h | 9 + target/i386/kvm/kvm.c | 12 target/i386/kvm/tdx-stub.c | 4 target/i386/kvm/tdx.c | 12 4 files changed, 37 insertions(+) diff --git a

[PATCH] i386/kvm: Disable hypercall patching quirk by default

2025-06-19 Thread Mathias Krause
KVM has a weird behaviour when a guest executes VMCALL on an AMD system or VMMCALL on an Intel CPU. Both naturally generate an invalid opcode exception (#UD) as they are just the wrong instruction for the CPU given. But instead of forwarding the exception to the guest, KVM tries to patch the guest

Re: [PATCH 2/2] block/rbd: support keyring option via QAPI

2025-06-19 Thread Ilya Dryomov
On Mon, Jun 16, 2025 at 2:51 PM Fiona Ebner wrote: > > Am 16.06.25 um 11:34 schrieb Ilya Dryomov: > > On Thu, May 15, 2025 at 1:29 PM Fiona Ebner wrote: > >> > >> In Proxmox VE, it is not always required to have a dedicated Ceph > >> configuration file, and using the 'key-secret' QAPI option woul

Re: [PATCH 1/2] block/rbd: support selected key-value-pairs via QAPI

2025-06-19 Thread Ilya Dryomov
On Mon, Jun 16, 2025 at 2:38 PM Fiona Ebner wrote: > > Am 16.06.25 um 12:28 schrieb Ilya Dryomov: > > On Mon, Jun 16, 2025 at 11:52 AM Daniel P. Berrangé > > wrote: > >> On Mon, Jun 16, 2025 at 11:25:54AM +0200, Ilya Dryomov wrote: > >>> On Thu, May 15, 2025 at 1:29 PM Fiona Ebner wrote: >

Re: [PATCH v4 4/8] hw/arm/virt-acpi-build: Fix comment in build_iort

2025-06-19 Thread Gustavo Romero
Hi Eric, On 6/17/25 10:22, Eric Auger wrote: Hi Gustavo, On 6/16/25 3:18 PM, Gustavo Romero wrote: The comment about the mapping from SMMU to ITS is incorrect and it reads "RC -> ITS". The code in question actually maps SMMU -> ITS, so the mapping in question is not direct. The direct mapping,

Re: [PATCH v12 0/7] Add additional plugin API functions to read and write memory and registers

2025-06-19 Thread Rowan Hart
I've updated this patch to address some notes about the build/test configuration for the patch plugin. Please check https://lore.kernel.org/qemu-devel/20250619161547.1401448-1-rowanbh...@gmail.com/T/#t instead. On 6/11/25 4:24 PM, Rowan Hart wrote: This patch series adds several new API funct

[PATCH v13 0/7] Add additional plugin API functions to read and write memory and registers

2025-06-19 Thread Rowan Hart
This patch series adds several new API functions focused on enabling use cases around reading and writing guest memory from QEMU plugins. To support these new APIs, some utility functionality around retrieving information about address spaces is added as well. The new qemu_plugin_write_register ut

[PATCH v13 7/7] plugins: Update plugin version and add notes

2025-06-19 Thread Rowan Hart
From: novafacing This patch updates the plugin version to gate new APIs and adds notes describing what has been added. Reviewed-by: Pierrick Bouvier Signed-off-by: Rowan Hart --- include/qemu/qemu-plugin.h | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/include/qem

[PATCH v13 3/7] plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W callbacks

2025-06-19 Thread Rowan Hart
This patch adds functionality to enforce the requested QEMU_PLUGIN_CB_ flags level passed when registering a callback function using the plugins API. Each time a callback is about to be invoked, a thread-local variable will be updated with the level that callback requested. Then, called API functio

[PATCH v13 5/7] plugins: Add memory hardware address read/write API

2025-06-19 Thread Rowan Hart
From: novafacing This patch adds functions to the plugins API to allow plugins to read and write memory via hardware addresses. The functions use the current address space of the current CPU in order to avoid exposing address space information to users. A later patch may want to add a function to

[PATCH v13 1/7] gdbstub: Expose gdb_write_register function to consumers of gdbstub

2025-06-19 Thread Rowan Hart
From: novafacing This patch exposes the gdb_write_register function from gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in plugins to write register contents. Reviewed-by: Alex Bennée Reviewed-by: Julian Ganz Reviewed-by: Pierrick Bouvier Signed-off-by: Rowan Hart --- g

[PATCH v13 6/7] plugins: Add patcher plugin and test

2025-06-19 Thread Rowan Hart
From: novafacing This patch adds a plugin that exercises the virtual and hardware memory read-write API functions added in a previous patch. The plugin takes a target and patch byte sequence, and will overwrite any instruction matching the target byte sequence with the patch. Signed-off-by: Rowa

[PATCH v13 4/7] plugins: Add memory virtual address write API

2025-06-19 Thread Rowan Hart
From: novafacing This patch adds functions to the plugins API to allow reading and writing memory via virtual addresses. These functions only permit doing so on the current CPU, because there is no way to ensure consistency if plugins are allowed to read or write to other CPUs that aren't current

[PATCH v13 2/7] plugins: Add register write API

2025-06-19 Thread Rowan Hart
From: novafacing This patch adds a function to the plugins API to allow plugins to write register contents. It also moves the qemu_plugin_read_register function so all the register-related functions are grouped together in the file. Reviewed-by: Pierrick Bouvier Signed-off-by: Rowan Hart ---

Re: [PATCH v5 5/5] hw/arm/virt: Allow virt extensions with KVM

2025-06-19 Thread Alyssa Ross
Eric Auger writes: > Hi, > > On 6/17/25 5:50 PM, Miguel Luis wrote: >> Hi Eric, >> >>> On 17 Jun 2025, at 15:41, Eric Auger wrote: >>> >>> >>> >>> On 6/17/25 5:23 PM, Miguel Luis wrote: Hi Alyssa, > On 17 Jun 2025, at 14:17, Alyssa Ross wrote: > > Eric Auger writes: >

Re: [PATCH v8 16/16] sev: Provide sev_features flags from IGVM VMSA to KVM_SEV_INIT2

2025-06-19 Thread Liam Merwick
On 13/06/2025 16:32, Roy Hopkins wrote: IGVM files can contain an initial VMSA that should be applied to each vcpu as part of the initial guest state. The sev_features flags are provided as part of the VMSA structure. However, KVM only allows sev_features to be set during initialization and no

Re: [PATCH v2] hw/arm/aspeed: add Catalina machine type

2025-06-19 Thread Cédric Le Goater
On 6/19/25 17:14, Patrick Williams wrote: Add the 'catalina-bmc' machine type based on the kernel DTS[1] as of 6.16-rc2. The i2c model is as complete as the current QEMU models support, but in some cases I substituted devices that are close enough for present functionality. Strap registers are

Re: [PATCH] hw/riscv/virt: Add acpi ged and powerdown support

2025-06-19 Thread Sunil V L
Hi Xuemei Liu, Thank you for the patch! On Thu, Jun 19, 2025 at 03:56:26PM +0800, liu.xuem...@zte.com.cn wrote: > From: Xuemei Liu > > This adds powerdown support by implementing the ACPI GED. > > Signed-off-by: Xuemei Liu > Co-authored-by: Björn Töpel > --- > hw/riscv/Kconfig |

[PATCH v2 4/7] hw/cxl/events: Updates for rev3.2 memory module event record

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose CXL spec rev3.2 section 8.2.10.2.1.3 Table 8-50, memory module event record has updated with following new fields. 1. Validity Flags 2. Component Identifier 3. Device Event Sub-Type Add updates for the above spec changes in the CXL memory module event reporting and QMP command t

[PATCH v2 7/7] hw/cxl: Add emulation for memory sparing control feature

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose Memory sparing is defined as a repair function that replaces a portion of memory with a portion of functional memory at that same DPA. The subclasses for this operation vary in terms of the scope of the sparing being performed. The Cacheline sparing subclass refers to a sparing a

[PATCH v2 1/7] hw/cxl/events: Update for rev3.2 common event record format

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose CXL spec 3.2 section 8.2.9.2.1 Table 8-55, Common Event Record format has updated with Maintenance Operation Subclass, LD ID and ID of the device head information. Add updates for the above spec changes in the related CXL events reporting and QMP command to inject CXL events. S

[PATCH v2 3/7] hw/cxl/events: Updates for rev3.2 DRAM event record

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose CXL spec rev3.2 section 8.2.10.2.1.2 Table 8-58, DRAM event record has updated with following new fields. 1. Component Identifier 2. Sub-channel of the memory event location 3. Advanced Programmable Corrected Memory Error Threshold Event Flags 4. Corrected Volatile Memory Error C

[PATCH v2 6/7] hw/cxl: Add Maintenance support

2025-06-19 Thread shiju . jose--- via
From: Davidlohr Bueso This adds initial support for the Maintenance command, specifically the soft and hard PPR operations on a dpa. The implementation allows to be executed at runtime, therefore semantically, data is retained and CXL.mem requests are correctly processed. Keep track of the reque

[PATCH v2 5/7] hw/cxl/cxl-mailbox-utils: Move declaration of scrub and ECS feature attributes in cmd_features_set_feature()

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose Move the declaration of scrub and ECS feature attributes in cmd_features_set_feature() to the local scope where they are used. Signed-off-by: Shiju Jose --- hw/cxl/cxl-mailbox-utils.c | 13 + 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/hw/cxl/cxl

[PATCH v2 0/7] hw/cxl: Update CXL events to rev3.2 and add maintenance support for memory repair features

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose Add updates for the CXL spec rev3.2 changes, in the CXL events reporting and QMP command to inject CXL events. Add maintenance support and emulation support for memory Post Package Repair(PPR) and memory sparing control features. Davidlohr Bueso (1): hw/cxl: Add Maintenance s

[PATCH v2 2/7] hw/cxl/events: Updates for rev3.2 general media event record

2025-06-19 Thread shiju . jose--- via
From: Shiju Jose CXL spec rev3.2 section 8.2.10.2.1.1 Table 8-57, general media event table has updated with following new fields. 1. Advanced Programmable Corrected Memory Error Threshold Event Flags 2. Corrected Memory Error Count at Event 3. Memory Event Sub-Type Add updates for the above spe

[PATCH v2] hw/arm/aspeed: add Catalina machine type

2025-06-19 Thread Patrick Williams
Add the 'catalina-bmc' machine type based on the kernel DTS[1] as of 6.16-rc2. The i2c model is as complete as the current QEMU models support, but in some cases I substituted devices that are close enough for present functionality. Strap registers are were verified with hardware. This has been

Re: aspeed: Split the machine definition into individual source files

2025-06-19 Thread Troy Lee
Hi, On Thu, Jun 19, 2025 at 5:24 PM Cédric Le Goater wrote: > > Hi, > > This is a follow up of a private discussion with Patrick. > > Aspeed modeling started nearly 10y ago with the palmetto-bmc machine. > We now have 5 SoCs and 25 machines which are mostly defined in > in a single aspeed.c file.

[PATCH v6 1/5] linux-headers: Update against v6.16-rc2

2025-06-19 Thread Eric Auger
This is a linux header update against v6.16-rc2 (e04c78d86a96), especially targeted to get nested virt enablement. Signed-off-by: Eric Auger --- include/standard-headers/asm-x86/setup_data.h | 13 +- include/standard-headers/drm/drm_fourcc.h | 45 +++ include/standard-headers/linux/eth

[PATCH v6 3/5] target/arm/kvm: Add helper to detect EL2 when using KVM

2025-06-19 Thread Eric Auger
From: Haibo Xu Introduce query support for KVM_CAP_ARM_EL2. Signed-off-by: Haibo Xu Signed-off-by: Miguel Luis Signed-off-by: Eric Auger Reviewed-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé --- target/arm/kvm_arm.h | 7 +++ target/arm/kvm-stub.c | 5 + target/arm/kvm

[PATCH v6 2/5] hw/arm: Allow setting KVM vGIC maintenance IRQ

2025-06-19 Thread Eric Auger
From: Haibo Xu Allow virt arm machine to set the interrupt ID for the KVM GIC maintenance interrupt. This setting must be done before the KVM_DEV_ARM_VGIC_CTRL_INIT hence the choice to perform the setting in the GICv3 realize instead of proceeding the same way as kvm_arm_pmu_set_irq(). Signed-o

[PATCH v6 4/5] target/arm: Enable feature ARM_FEATURE_EL2 if EL2 is supported

2025-06-19 Thread Eric Auger
From: Haibo Xu KVM_CAP_ARM_EL2 must be supported by the cpu to enable ARM_FEATURE_EL2. In case the host does support NV, expose the feature. Signed-off-by: Haibo Xu Signed-off-by: Miguel Luis Signed-off-by: Eric Auger Reviewed-by: Richard Henderson --- v2 -> v3: - check pmu->has_el2 on kvm_

[PATCH v6 0/5] ARM Nested Virt Support

2025-06-19 Thread Eric Auger
The only change compared to v5 is the linux header update against kvm main branch. As discussed on the mailing list, KVM_ARM_VCPU_EL2_E2H0 (non VHE version of the NV support) will be dealt with in a separate add-on series. Also the fallback to TCG does not apply if the host does not support nested

[PATCH v6 5/5] hw/arm/virt: Allow virt extensions with KVM

2025-06-19 Thread Eric Auger
From: Haibo Xu Up to now virt support on guest has been only supported with TCG. Now it becomes feasible to use it with KVM acceleration. Also check only in-kernel GICv3 is used along with KVM EL2. Signed-off-by: Haibo Xu Signed-off-by: Miguel Luis Signed-off-by: Eric Auger Reviewed-by: Rich

Re: [PATCH 20/20] tests/functional/sbsa-ref: Move where machine type is set

2025-06-19 Thread Leif Lindholm
On Thu, 19 Jun 2025 at 14:23, Philippe Mathieu-Daudé wrote: > > On Thu, 19 Jun 2025 at 15:15, Philippe Mathieu-Daudé > wrote: > > > > fetch_firmware() is only about fetching firmware. > > Set the machine type in test_sbsaref_edk2_firmware(). > > > > Signed-off-by: Philippe Mathieu-Daudé > > ---

Re: [PATCH v7 3/5] memory: Unify the definiton of ReplayRamPopulate() and ReplayRamDiscard()

2025-06-19 Thread Peter Xu
On Thu, Jun 19, 2025 at 11:06:46AM +0800, Chenyi Qiang wrote: > To fix the build error with --enable-docs configuration, Add the below fixup Thanks, this works for me. Though I just noticed it has more than the doc issue.. please see: https://gitlab.com/peterx/qemu/-/jobs/10403528070 So 6 failu

[PATCH v3] Add RISCV ZALASR extension

2025-06-19 Thread Roan Richmond
This is based on version v0.8.3 of the ZALASR specification [1]. The specification is listed as in Frozen state [2]. [1]: https://github.com/riscv/riscv-zalasr/tree/v0.8.3 [2]: https://lf-riscv.atlassian.net/wiki/spaces/HOME/pages/16154882/All+RISC-V+Specifications+Under+Active+Development Signe

[PATCH v4 17/19] vfio-user: add coalesced posted writes

2025-06-19 Thread John Levon
Add new message to send multiple writes to server in a single message. Prevents the outgoing queue from overflowing when a long latency operation is followed by a series of posted writes. Originally-by: John Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by:

[PATCH v4 09/19] vfio-user: implement VFIO_USER_DEVICE_GET/SET_IRQ*

2025-06-19 Thread John Levon
IRQ setup uses the same semantics as the traditional vfio path, but we need to share the corresponding file descriptors with the server as necessary. Originally-by: John Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John Levon --- hw/vfio-user/protocol

[PATCH v4 12/19] vfio-user: implement VFIO_USER_DEVICE_RESET

2025-06-19 Thread John Levon
Hook this call up to the legacy reset handler for vfio-user-pci. Originally-by: John Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John Levon --- hw/vfio-user/device.h | 2 ++ hw/vfio-user/device.c | 12 hw/vfio-user/pci.c| 15 +++

Re: [PATCH 19/20] hw/arm/sbsa-ref: Tidy up use of RAMLIMIT_GB definition

2025-06-19 Thread Leif Lindholm
On Thu, 19 Jun 2025 at 14:15, Philippe Mathieu-Daudé wrote: > > Define RAMLIMIT_BYTES using the TiB definition and display > the error parsed with size_to_str(): > > $ qemu-system-aarch64-unsigned -M sbsa-ref -m 9T > qemu-system-aarch64-unsigned: sbsa-ref: cannot model more than 8 TiB of RAM >

[PATCH v4 15/19] vfio-user: add 'x-msg-timeout' option

2025-06-19 Thread John Levon
By default, the vfio-user subsystem will wait 5 seconds for a message reply from the server. Add an option to allow this to be configurable. Originally-by: John Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John Levon --- hw/vfio-user/proxy.h | 1 + hw

  1   2   >