Re: ppc kvm: support of 64K guest page size with 4K host pagesize?

2025-06-04 Thread Thomas Huth
On 05/06/2025 08.34, Michael Tokarev wrote: There's a bug report filed in debian against qemu, https://bugs.debian.org/1107288 - saying kvm on ppc does not work on debian (anymore) due to qemu requesting unrealistic (non-existing) page size of 64K on a host which only has 4K. I don't know much a

Re: [PATCH v4 2/2] target/riscv: Make PMP region count configurable

2025-06-04 Thread Alistair Francis
On Thu, Jun 5, 2025 at 3:34 PM Jay Chang wrote: > > Hi Daniel, > > You're absolutely right — thanks for pointing it out and providing the fix! > > Would you like me to send out a v5 patch incorporating your changes? Yes please Alistair > > > Best Regards > Jay Chang > > > On Thu, Jun 5, 2025 at

Re: [PATCH v2] target/riscv: support atomic instruction fetch (Ziccif)

2025-06-04 Thread Alistair Francis
On Thu, May 8, 2025 at 7:49 PM Jim Shu wrote: > > Support 4-byte atomic instruction fetch when instruction is natural > aligned. > > Current implementation is not atomic because it loads instruction twice > for first and last 2 bytes. We load 4 bytes at once to keep the > atomicity. This instructi

Re: [PATCH v5 0/6] python: add QAPI and qapidoc et al to python tests

2025-06-04 Thread Markus Armbruster
John Snow writes: > Hiya, this series turns on automated linting for scripts/qapi, > docs/sphinx/qapidoc.py and docs/sphinx/qapi_domain.py. > > This includes flake8/isort/pylint/mypy for scripts/qapi, but omits mypy > from the Sphinx plugins owing to my inability to strictly type the > extensions

ppc kvm: support of 64K guest page size with 4K host pagesize?

2025-06-04 Thread Michael Tokarev
There's a bug report filed in debian against qemu, https://bugs.debian.org/1107288 - saying kvm on ppc does not work on debian (anymore) due to qemu requesting unrealistic (non-existing) page size of 64K on a host which only has 4K. I don't know much about PPC, - what's the issue here? Should qem

Re: [PATCH v5 4/6] python: add qapi static analysis tests

2025-06-04 Thread Markus Armbruster
John Snow writes: [...] > diff --git a/python/tests/qapi-flake8.sh b/python/tests/qapi-flake8.sh > new file mode 100755 > index 000..2211b6c7f41 > --- /dev/null > +++ b/python/tests/qapi-flake8.sh > @@ -0,0 +1,6 @@ > +#!/bin/sh -e > +# SPDX-License-Identifier: LGPL-2.1-or-later Why not

Re: [PATCH v5 4/6] python: add qapi static analysis tests

2025-06-04 Thread Markus Armbruster
John Snow writes: > Update the python tests to also check QAPI and the QAPI Sphinx [Lovingly crafted commit message snipped...] > Signed-off-by: John Snow > > add licenses or whatever > > Signed-off-by: John Snow Oops!

Re: [PATCH 06/14] rust: qemu-api: add bindings to Error

2025-06-04 Thread Markus Armbruster
Paolo Bonzini writes: > On 6/4/25 07:01, Markus Armbruster wrote: >> This is what your FOO_or_propagate() functions are for. >> >> The rule glosses over a subtle detail: the difference between >> error_setg() and error_propagate() isn't just create a new error vs. use >> an existing one, namely

[PATCH] accel/tcg: Make round-robin kick period configurable

2025-06-04 Thread Ethan Chen via
This change introduces a configurable round-robin kick period, giving users the flexibility to balance SMP simulation accuracy and performance according to their specific needs. The round-robin kick period is the time one vCPU can run before scheduler switches to another vCPU when using a single t

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

2025-06-04 Thread Chenyi Qiang
On 6/4/2025 7:04 PM, Alexey Kardashevskiy wrote: > > > On 30/5/25 18:32, 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 opera

Re: [PATCH v4 2/2] target/riscv: Make PMP region count configurable

2025-06-04 Thread Jay Chang
*Hi Daniel,* You're absolutely right — thanks for pointing it out and providing the fix! Would you like me to send out a v5 patch incorporating your changes? Best Regards Jay Chang On Thu, Jun 5, 2025 at 2:20 AM Daniel Henrique Barboza < dbarb...@ventanamicro.com> wrote: > It seems like this

RE: [PATCH v5 0/7] ui/spice: Enable gl=on option for non-local or remote clients

2025-06-04 Thread Kasireddy, Vivek
Hi Marc-André, > Subject: Re: [PATCH v5 0/7] ui/spice: Enable gl=on option for non-local or > remote clients > > > > > To address the limitation that this option is incompatible with > > remote clients, this patch series adds an option to select a > > preferred codec and also enable gl=on option

Re: [PATCH 0/8] hw/i386/pc: Remove deprecated 2.10, 2.11 and 2.12 PC machines

2025-06-04 Thread Xiaoyao Li
On 6/4/2025 3:14 PM, Philippe Mathieu-Daudé wrote: On 4/6/25 09:07, Philippe Mathieu-Daudé wrote: On 4/6/25 03:30, Xiaoyao Li wrote: On 5/2/2025 6:35 AM, Philippe Mathieu-Daudé wrote: The versioned 'pc' and 'q35' machines up to 2.12 been marked as deprecated two releases ago, and are older tha

Re: [PATCH v1] ramfb: Add property to control if load the romfile

2025-06-04 Thread Philippe Mathieu-Daudé
Hi Shaoqin, On 5/6/25 05:03, Shaoqin Huang wrote: Now the ramfb will load the vgabios-ramfb.bin unconditionally, but only the x86 need the vgabios-ramfb.bin, this can cause that when use the release package on arm64 it can't find the vgabios-ramfb.bin. So add a new property ramfb-romfile in bot

Re: [PATCH 00/11] SVM API declaration for emulated devices

2025-06-04 Thread CLEMENT MATHIEU--DRIF
Just cc'ing riscv team Thanks >cmd On 20/05/2025 9:18 am, CLEMENT MATHIEU--DRIF wrote: > This patch set belongs to a list of series that add SVM support in VT-d. > > Here we focus on introducing a common PCI-level API for ATS and PRI to be > used by virtual devices. > > The API introduced in thi

Re: [PATCH 0/2] ui: fix VNC endian regression & improve tracing

2025-06-04 Thread Philippe Mathieu-Daudé
On 4/6/25 18:22, Daniel P. Berrangé wrote: Daniel P. Berrangé (2): ui: fix setting client_endian field defaults ui: add trace events for all client messages Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH v2] target/riscv: support atomic instruction fetch (Ziccif)

2025-06-04 Thread Alistair Francis
On Thu, May 8, 2025 at 7:49 PM Jim Shu wrote: > > Support 4-byte atomic instruction fetch when instruction is natural > aligned. > > Current implementation is not atomic because it loads instruction twice > for first and last 2 bytes. We load 4 bytes at once to keep the > atomicity. This instructi

Re: [PATCH v2 2/3] target/riscv/tcg: decouple profile enablement from user prop

2025-06-04 Thread Alistair Francis
On Thu, Jun 5, 2025 at 3:40 AM Daniel Henrique Barboza wrote: > > We have code in riscv_cpu_add_profiles() to enable a profile right away > in case a CPU chose the profile during its cpu_init(). But we're using > the user callback option to do so, setting profile->user_set. > > Create a new helper

Re: [PATCH RESEND v2 3/3] target/riscv/cpu.c: do better with 'named features' doc

2025-06-04 Thread Alistair Francis
On Thu, Jun 5, 2025 at 3:45 AM Daniel Henrique Barboza wrote: > > Most of the named features are added directly in isa_edata_arr[], some > of them are also added in riscv_cpu_named_features(). There is a reason > for that, and the existing docs can do better explaining it. > > Signed-off-by: Danie

Re: [PATCH RESEND v2 1/3] target/riscv/cpu.c: add 'sdtrig' in riscv, isa

2025-06-04 Thread Alistair Francis
On Thu, Jun 5, 2025 at 3:45 AM Daniel Henrique Barboza wrote: > > We have support for sdtrig for awhile but we are not advertising it. It > is enabled by default via the 'debug' flag. Use the same flag to also > advertise sdtrig. > > Add an exception in disable_priv_spec_isa_exts() to avoid spammi

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

2025-06-04 Thread Chenyi Qiang
On 6/5/2025 8:35 AM, Alexey Kardashevskiy wrote: > > > On 4/6/25 21:04, Alexey Kardashevskiy wrote: >> >> >> On 30/5/25 18:32, Chenyi Qiang wrote: >>> Commit 852f0048f3 ("RAMBlock: make guest_memfd require uncoordinated >>> discard") highlighted that subsystems like VFIO may disable RAM block

[PATCH v1] ramfb: Add property to control if load the romfile

2025-06-04 Thread Shaoqin Huang
Now the ramfb will load the vgabios-ramfb.bin unconditionally, but only the x86 need the vgabios-ramfb.bin, this can cause that when use the release package on arm64 it can't find the vgabios-ramfb.bin. So add a new property ramfb-romfile in both ramfb and vfio_pci device, because the vfio display

Re: [PATCH 1/3] trace/syslog: seperate cold paths of tracing functions

2025-06-04 Thread Tanish Desai
Yes, you're right—there was a mistake in the original commit description. In this change, we're moving cold paths out of the header (.h) files and into corresponding source (.c) files. The primary motivation is to avoid replicating the cold path logic across every translation unit that includes tra

RE: [PATCH V4 04/43] vfio/pci: vfio_pci_put_device on failure

2025-06-04 Thread Duan, Zhenzhong
>-Original Message- >From: Steven Sistare >Subject: Re: [PATCH V4 04/43] vfio/pci: vfio_pci_put_device on failure > >On 6/3/2025 11:55 PM, Duan, Zhenzhong wrote: >>> -Original Message- >>> From: Steven Sistare >>> Subject: Re: [PATCH V4 04/43] vfio/pci: vfio_pci_put_device on fa

Re: [PATCH v3 0/6] hw/arm/virt: Add support for user creatable SMMUv3 device

2025-06-04 Thread Donald Dutile
On 6/4/25 10:02 PM, Nathan Chen wrote: On 6/2/2025 8:41 AM, Shameer Kolothum wrote: This patch series introduces support for a user-creatable SMMUv3 device (-device arm-smmuv3) in QEMU. Tested-by: Nathan Chen I am able to create 16 SMMUv3 devices in a qemu VM with emulated devices proper

[PATCH v6] target/loongarch: fix vldi/xvldi raise wrong error

2025-06-04 Thread Song Gao
on qemu we got an aborted error ** ERROR:../target/loongarch/tcg/insn_trans/trans_vec.c.inc:3574:vldi_get_value: code should not be reached Bail out! ERROR:../target/loongarch/tcg/insn_trans/trans_vec.c.inc:3574:vldi_get_value: code should not be reached Aborted (core dumped) but on 3A600/3A5000

Re: [PATCH v3 0/6] hw/arm/virt: Add support for user creatable SMMUv3 device

2025-06-04 Thread Nathan Chen
On 6/2/2025 8:41 AM, Shameer Kolothum wrote: This patch series introduces support for a user-creatable SMMUv3 device (-device arm-smmuv3) in QEMU. Tested-by: Nathan Chen I am able to create 16 SMMUv3 devices in a qemu VM with emulated devices properly associated with the guest SMMUs in guest

Re: [PATCH v5] target/loongarch: fix vldi/xvldi raise wrong error

2025-06-04 Thread gaosong
在 2025/6/4 下午7:23, Michael Tokarev 写道: On 04.06.2025 11:40, Song Gao wrote: +static bool check_vldi_mode(arg_vldi *a) +{ +   return (a->imm >>8 & 0xf) <= 12; +}   static bool gen_vldi(DisasContext *ctx, arg_vldi *a, uint32_t oprsz)   { An empty line can be added here between two functions dur

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

2025-06-04 Thread Alexey Kardashevskiy
On 4/6/25 21:04, Alexey Kardashevskiy wrote: On 30/5/25 18:32, 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 c

[PATCH v3 05/28] s390x/diag: Introduce DIAG 320 for certificate store facility

2025-06-04 Thread Zhuoying Cai
DIAGNOSE 320 is introduced to support certificate store facility, which includes operations such as query certificate storage information and provide certificates in the certificate store. Currently, only subcode 0 is supported with this patch, which is used to query a bitmap of which subcodes are

[PATCH v3 19/28] pc-bios/s390-ccw: Refactor zipl_load_segment function

2025-06-04 Thread Zhuoying Cai
Make the address variable a parameter of zipl_load_segment and return segment length. Modify this function for reuse in the next patch, which allows loading segment or signature data to the destination memory address. Add a comp_len variable to store the length of a segment and return this variab

Re: [PATCH 0/3] docs: Bump sphinx to 6.2.1

2025-06-04 Thread John Snow
On Mon, May 19, 2025 at 1:47 PM John Snow wrote: > > > On Sat, May 10, 2025 at 2:17 AM Akihiko Odaki > wrote: > >> Supersedes: <20250505-sphinx82-v1-0-85f2418b3...@daynix.com> >> ("[PATCH 0/2] docs: Bump sphinx to 8.2.3") >> >> sphinx 5.3.0 fails with Python 3.13.1: >> >> ../docs/meson.build:37:

[PATCH v3 23/28] Add secure-boot to s390-ccw-virtio machine type option

2025-06-04 Thread Zhuoying Cai
Add secure-boot as a parameter of s390-ccw-virtio machine type option. The `secure-boot=on|off` parameter is implemented to enable secure IPL. By default, secure-boot is set to false if not specified in the command line. Signed-off-by: Zhuoying Cai --- hw/s390x/s390-virtio-ccw.c | 22 +

[PATCH v3 27/28] hw/s390x/ipl: Handle secure boot without specifying a boot device

2025-06-04 Thread Zhuoying Cai
If secure boot in audit mode or True Secure IPL mode is enabled without specifying a boot device, the boot process will terminate with an error. Signed-off-by: Zhuoying Cai --- hw/s390x/ipl.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c index a1

[PATCH v3 28/28] docs: Add secure IPL documentation

2025-06-04 Thread Zhuoying Cai
Add documentation for secure IPL Signed-off-by: Collin Walling Signed-off-by: Zhuoying Cai --- docs/specs/s390x-secure-ipl.rst | 145 +++ docs/system/s390x/secure-ipl.rst | 129 +++ 2 files changed, 274 insertions(+) create mode 100644 docs/

[PATCH v3 26/28] pc-bios/s390-ccw: Handle secure boot with multiple boot devices

2025-06-04 Thread Zhuoying Cai
The current approach to enabling secure boot relies on providing -secure-boot and -boot-certificates options, which apply to all boot devices. With the possibility of multiple boot devices, secure boot expects all provided devices to be supported and eligible (e.g., virtio-blk/virtio-scsi using th

[PATCH v3 06/28] s390x/diag: Refactor address validation check from diag308_parm_check

2025-06-04 Thread Zhuoying Cai
Create a function to validate the address parameter of DIAGNOSE. Refactor the function for reuse in the next patch, which allows address validation in read or write operation of DIAGNOSE. Signed-off-by: Zhuoying Cai --- hw/s390x/ipl.h | 6 ++ target/s390x/diag.c | 4 +--- 2 files chang

[PATCH v3 22/28] pc-bios/s390-ccw: Add additional security checks for secure boot

2025-06-04 Thread Zhuoying Cai
Add additional checks to ensure that components do not overlap with signed components when loaded into memory. Add additional checks to ensure the load addresses of unsigned components are greater than or equal to 0x2000. When the secure IPL code loading attributes facility (SCLAF) is installed,

[PATCH v3 13/28] pc-bios/s390-ccw: Introduce IPL Information Report Block (IIRB)

2025-06-04 Thread Zhuoying Cai
The IPL information report block (IIRB) contains information used to locate IPL records and to report the results of signature verification of one or more secure components of the load device. IIRB is stored immediately following the IPL Parameter Block. Results on component verification in any ca

[PATCH v3 17/28] s390x: Guest support for Secure-IPL Facility

2025-06-04 Thread Zhuoying Cai
Introduce Secure-IPL (SIPL) facility. Use fac_ipl to represent bytes 136 and 137 for IPL device facilities of the SCLP Read Info block. Availability of SIPL facility is determined by byte 136 bit 1 of the SCLP Read Info block. Byte 136's facilities cannot be represented without the availability o

[PATCH v3 02/28] crypto/x509-utils: Add helper functions for certificate store

2025-06-04 Thread Zhuoying Cai
Add helper functions for x509 certificate which will be used in the next patch for the certificate store. Signed-off-by: Zhuoying Cai --- crypto/meson.build | 5 +- crypto/x509-utils.c | 166 include/crypto/x509-utils.h | 54

[PATCH v3 01/28] Add boot-certificates to s390-ccw-virtio machine type option

2025-06-04 Thread Zhuoying Cai
Add boot-certificates as a parameter of s390-ccw-virtio machine type option. The `boot-certificates=/path/dir:/path/file` parameter is implemented to provide path to either a directory or a single certificate. Multiple paths can be delineated using a colon. Signed-off-by: Zhuoying Cai --- hw/s

[PATCH v3 00/28] Secure IPL Support for SCSI Scheme of virtio-blk/virtio-scsi Devices

2025-06-04 Thread Zhuoying Cai
Changelog v2->v3: - Fixed typos in patches - Edited and corrected patch description - Enabled secure IPL feature in TCG - Split crypto subsystem changes from s390x subsystem changes - Added API documentation for each helper function - Removed qcrypto_get_x509_cert_fmt() - Reworked qcry

[PATCH v3 09/28] s390x/diag: Implement DIAG 320 subcode 2

2025-06-04 Thread Zhuoying Cai
DIAG 320 subcode 2 provides verification-certificates (VCs) that are in the certificate store. Only X509 certificates in DER format and SHA-256 hash type are recognized. The subcode value is denoted by setting the second-left-most bit of an 8-byte field. The Verification Certificate Block (VCB) c

[PATCH v3 21/28] s390x: Guest support for Secure-IPL Code Loading Attributes Facility (SCLAF)

2025-06-04 Thread Zhuoying Cai
The secure-IPL-code-loading-attributes facility (SCLAF) provides additional security during IPL. Availability of SCLAF is determined by byte 136 bit 3 of the SCLP Read Info block. Signed-off-by: Zhuoying Cai --- target/s390x/cpu_features.c | 1 + target/s390x/cpu_features_def.h.inc | 1

[PATCH v3 16/28] hw/s390x/ipl: Set iplb->len to maximum length of IPL Parameter Block

2025-06-04 Thread Zhuoying Cai
The IPL Information Report Block (IIRB) immediately follows the IPL Parameter Block (IPLB). The IPLB struct is allocated 4KB in memory, and iplb->len indicates the amount of memory currently used by the IPLB. To ensure proper alignment of the IIRB and prevent overlap, set iplb->len to the maximum

[PATCH v3 18/28] pc-bios/s390-ccw: Refactor zipl_run()

2025-06-04 Thread Zhuoying Cai
Refactor to enhance readability before enabling secure IPL in later patches. Signed-off-by: Zhuoying Cai --- pc-bios/s390-ccw/bootmap.c | 58 ++ 1 file changed, 34 insertions(+), 24 deletions(-) diff --git a/pc-bios/s390-ccw/bootmap.c b/pc-bios/s390-ccw/bootm

[PATCH v3 24/28] hw/s390x/ipl: Set IPIB flags for secure IPL

2025-06-04 Thread Zhuoying Cai
If `-secure-boot on` is specified on the command line option, indicating true secure IPL enabled, set Secure-IPL bit and IPL-Information-Report bit on in IPIB Flags field, and trigger true secure IPL in the S390 BIOS. Any error that occurs during true secure IPL will cause the IPL to terminate. S

[PATCH v3 25/28] pc-bios/s390-ccw: Handle true secure IPL mode

2025-06-04 Thread Zhuoying Cai
When secure boot is enabled (-secure-boot on) and certificate(s) are provided, the boot operates in True Secure IPL mode. Any verification error during True Secure IPL mode will cause the entire boot process to terminate. Secure IPL in audit mode requires at least one certificate provided in the

[PATCH v3 11/28] crypto: Add helper functions for DIAG 508 subcode 1

2025-06-04 Thread Zhuoying Cai
Add helper functions for x509 certificate which will be used in the next patch for DIAG 508 subcode 1. Signed-off-by: Zhuoying Cai --- crypto/x509-utils.c | 61 + include/crypto/x509-utils.h | 20 2 files changed, 81 insertions(+) diff --

[PATCH v3 12/28] s390x/diag: Implement DIAG 508 subcode 1 for signature verification

2025-06-04 Thread Zhuoying Cai
From: Collin Walling DIAG 508 subcode 1 performs signature-verification on signed components. A signed component may be a Linux kernel image, or any other signed binary. **Verification of initrd is not supported.** The instruction call expects two item-pairs: an address of a device component, an

[PATCH v3 15/28] hw/s390x/ipl: Add IPIB flags to IPL Parameter Block

2025-06-04 Thread Zhuoying Cai
Add IPIB flags to IPL Parameter Block to determine if IPL needs to perform securely and if IPL Information Report Block (IIRB) exists. Move DIAG308 flags to a separated header file and add flags for secure IPL. Secure boot in audit mode will perform if certificate(s) exist in the key store. IIRB

[PATCH v3 04/28] s390x: Guest support for Certificate Store Facility (CS)

2025-06-04 Thread Zhuoying Cai
DIAG 320 is supported when the certificate-store (CS) facility is installed. Availability of CS facility is determined by byte 134 bit 5 of the SCLP Read Info block. Byte 134's facilities cannot be represented without the availability of the extended-length-SCCB, so add it as a check for consisten

[PATCH v3 14/28] pc-bios/s390-ccw: Define memory for IPLB and convert IPLB to pointers

2025-06-04 Thread Zhuoying Cai
Define a memory space for both IPL Parameter Block (IPLB) and IPL Information Report Block (IIRB) since IIRB is stored immediately following IPLB. Convert IPLB to pointer and it points to the start of the defined memory space. IIRB points to the end of IPLB. Signed-off-by: Zhuoying Cai --- pc-b

[PATCH v3 20/28] pc-bios/s390-ccw: Add signature verification for secure IPL in audit mode

2025-06-04 Thread Zhuoying Cai
Enable secure IPL in audit mode, which performs signature verification, but any error does not terminate the boot process. Only warnings will be logged to the console instead. Add a comp_len variable to store the length of a segment in zipl_load_segment. comp_len variable is necessary to store the

[PATCH v3 10/28] s390x/diag: Introduce DIAG 508 for secure IPL operations

2025-06-04 Thread Zhuoying Cai
From: Collin Walling In order to support secure IPL (aka secure boot) for the s390-ccw BIOS, a new s390 DIAGNOSE instruction is introduced to leverage QEMU for handling operations such as signature verification and certificate retrieval. Currently, only subcode 0 is supported with this patch, wh

[PATCH v3 03/28] hw/s390x/ipl: Create certificate store

2025-06-04 Thread Zhuoying Cai
Create a certificate store for boot certificates used for secure IPL. Load certificates from the boot-certificate parameter of s390-ccw-virtio machine type option into the cert store. Currently, only x509 certificates in DER format and uses SHA-256 hashing algorithm are supported, as these are th

[PATCH v3 08/28] crypto/x509-utils: Add helper functions for DIAG 320 subcode 2

2025-06-04 Thread Zhuoying Cai
Add helper functions for x509 certificate which will be used in the next patch for DIAG 320 subcode 2. Signed-off-by: Zhuoying Cai --- crypto/x509-utils.c | 190 +++- include/crypto/x509-utils.h | 63 qapi/crypto.json| 20 3

[PATCH v3 07/28] s390x/diag: Implement DIAG 320 subcode 1

2025-06-04 Thread Zhuoying Cai
DIAG 320 subcode 1 provides information needed to determine the amount of storage to store one or more certificates. The subcode value is denoted by setting the left-most bit of an 8-byte field. The verification-certificate-storage-size block (VCSSB) contains the output data when the operation co

Synced invitation: QEMU/KVM developers conference call @ Every 2 weeks from 4pm to 5pm on Tuesday (GMT+3) (qemu-devel@nongnu.org)

2025-06-04 Thread Meirav Dean via
BEGIN:VCALENDAR PRODID:-//Google Inc//Google Calendar 70.9054//EN VERSION:2.0 CALSCALE:GREGORIAN METHOD:REQUEST BEGIN:VTIMEZONE TZID:America/New_York X-LIC-LOCATION:America/New_York BEGIN:DAYLIGHT TZOFFSETFROM:-0500 TZOFFSETTO:-0400 TZNAME:EDT DTSTART:19700308T02 RRULE:FREQ=YEARLY;BYMONTH=3;BYD

Synced invitation: QEMU/KVM developers conference call @ Every 2 weeks from 4pm to 5pm on Tuesday from Tue Feb 4 to Tue Jun 10 (GMT+2) (qemu-devel@nongnu.org)

2025-06-04 Thread Meirav Dean via
BEGIN:VCALENDAR PRODID:-//Google Inc//Google Calendar 70.9054//EN VERSION:2.0 CALSCALE:GREGORIAN METHOD:REQUEST BEGIN:VTIMEZONE TZID:America/New_York X-LIC-LOCATION:America/New_York BEGIN:DAYLIGHT TZOFFSETFROM:-0500 TZOFFSETTO:-0400 TZNAME:EDT DTSTART:19700308T02 RRULE:FREQ=YEARLY;BYMONTH=3;BYD

Re: [PATCH v4 1/1] hw/riscv: fix PLIC hart topology configuration string when not getting CPUState correctly

2025-06-04 Thread Daniel Henrique Barboza
Hi, This patch is faling 'make check-functional': 2/12 qemu:func-quick+func-riscv64 / func-riscv64-riscv_opensbi ERROR1.25s exit status 1 4/12 qemu:func-quick+func-riscv32 / func-riscv32-riscv_opensbi ERROR1.39s exit st

[PATCH v5 2/6] docs/qapidoc: linting fixes

2025-06-04 Thread John Snow
This restores the linting baseline in qapidoc. The order of some imports change slightly here due to configuring isort a little better: previously, isort was having difficulty understanding that "compat" and "qapidoc_legacy" were local modules because docs/sphinx "isn't a python package". Configuri

[PATCH v5 5/6] python: Drop redundant warn_unused_configs = True

2025-06-04 Thread John Snow
From: Markus Armbruster strict = True implies warn_unused_configs = True. Signed-off-by: Markus Armbruster Signed-off-by: John Snow --- python/setup.cfg | 1 - 1 file changed, 1 deletion(-) diff --git a/python/setup.cfg b/python/setup.cfg index d21304cadd1..d7f5dc7bafe 100644 --- a/python/se

[PATCH v5 3/6] python: update missing dependencies from minreqs

2025-06-04 Thread John Snow
We pin all dependencies for the "check-minreqs" test because pip lacks a dependency resolver that installs "the oldest possible package that meets dependency criteria". So, in order to test our stated minimum requirements, we pin all of our dependencies (and their dependencies, transitively) at the

[PATCH v5 0/6] python: add QAPI and qapidoc et al to python tests

2025-06-04 Thread John Snow
Hiya, this series turns on automated linting for scripts/qapi, docs/sphinx/qapidoc.py and docs/sphinx/qapi_domain.py. This includes flake8/isort/pylint/mypy for scripts/qapi, but omits mypy from the Sphinx plugins owing to my inability to strictly type the extensions given the wide versions of Sph

[PATCH v5 4/6] python: add qapi static analysis tests

2025-06-04 Thread John Snow
Update the python tests to also check QAPI and the QAPI Sphinx extensions. The docs/sphinx/qapidoc_legacy.py file is not included in these checks, as it is destined for removal soon. mypy is also not called on the QAPI Sphinx extensions, owing to difficulties supporting Sphinx 3.x - 8.x while maint

[PATCH v5 6/6] qapi: delete un-needed python static analysis configs

2025-06-04 Thread John Snow
Since the previous commit, python/setup.cfg applies to scripts/qapi/ as well. Configuration files in scripts/qapi/ override python/setup.cfg. scripts/qapi/.flake8 and scripts/qapi/.isort.cfg actually match python/setup.cfg exactly, and can go. The differences between scripts/qapi/mypy.ini and py

[PATCH v5 1/6] qapi: Add some pylint ignores

2025-06-04 Thread John Snow via
This restores the linting baseline in QAPI. Signed-off-by: John Snow --- scripts/qapi/backend.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/qapi/backend.py b/scripts/qapi/backend.py index 14e60aa67af..49ae6ecdd33 100644 --- a/scripts/qapi/backend.py +++ b/scripts/qapi/backend.

[PATCH] virtio: avoid cost of -ftrivial-auto-var-init in hot path

2025-06-04 Thread Stefan Hajnoczi
Since commit 7ff9ff039380 ("meson: mitigate against use of uninitialize stack for exploits") the -ftrivial-auto-var-init=zero compiler option is used to zero local variables. While this reduces security risks associated with uninitialized stack data, it introduced a measurable bottleneck in the vir

Re: [PATCH 06/14] rust: qemu-api: add bindings to Error

2025-06-04 Thread Paolo Bonzini
On 6/4/25 07:01, Markus Armbruster wrote: This is what your FOO_or_propagate() functions are for. The rule glosses over a subtle detail: the difference between error_setg() and error_propagate() isn't just create a new error vs. use an existing one, namely error_setg() makes the precondition vio

Re: [PATCH 0/2] ui: fix VNC endian regression & improve tracing

2025-06-04 Thread Marc-André Lureau
On Wed, Jun 4, 2025 at 8:22 PM Daniel P. Berrangé wrote: > > > Daniel P. Berrangé (2): > ui: fix setting client_endian field defaults > ui: add trace events for all client messages > > ui/trace-events | 14 + > ui/vnc.c| 53

Re: [PATCH v4 2/2] target/riscv: Make PMP region count configurable

2025-06-04 Thread Daniel Henrique Barboza
It seems like this patch is breaking 'make check-functional': UBSAN_OPTIONS=halt_on_error=1:abort_on_error=1:print_summary=1:print_stacktrace=1 RUST_BACKTRACE=1 LD_LIBRARY_PATH=/home/danielhb/work/qemu/build/contrib/plugins:/home/danielhb/work/qemu/build/tests/tcg/plugins MSAN_OPTIONS=halt_

[PULL 20/24] iotests/graph-changes-while-io: remove image file after test

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner Suggested-by: Kevin Wolf Signed-off-by: Fiona Ebner Message-ID: <20250530151125.955508-21-f.eb...@proxmox.com> Reviewed-by: Kevin Wolf Signed-off-by: Kevin Wolf --- tests/qemu-iotests/tests/graph-changes-while-io | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/qem

[PULL 14/24] block: move drain outside of quorum_add_child()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". The quorum_add_child() callback runs under the graph lock, so it is not allowed to drain. It is only called as the .bdrv_add_child() callbac

[PULL 24/24] hw/core/qdev-properties-system: Add missing return in set_drive_helper()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner Currently, changing the 'drive' property of e.g. a scsi-hd object will result in an assertion failure if the aio context of the block node it's replaced with doesn't match the current aio context: > bdrv_replace_child_noperm: Assertion `bdrv_get_aio_context(old_bs) == > bdrv_ge

[PULL 18/24] blockdev: drain while unlocked in external_snapshot_action()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. Signed-off-by: Fiona Ebner Message-ID: <20250530151125.955508-19-f.eb...@proxmox.com> Reviewed-by: Kevin Wolf Signed-off-by: Kevin Wolf --- blockdev.c | 17 - 1 file changed, 16 insertion

[PULL 08/24] block: move drain outside of bdrv_change_aio_context() and mark GRAPH_RDLOCK

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. Note that even if bdrv_drained_begin() were already marked as GRAPH_UNLOCKED, TSA would not complain about the instance in bdrv_change_aio_context() before this change, because it is preceded by a bdrv_graph

[PULL 15/24] block: move drain outside of bdrv_root_unref_child()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". bdrv_root_unref_child() is called by: 1. blk_remove_bs(), where a drained section is introduced. 2. bdrv_unref_child(), which runs under the

[PULL 12/24] block: move drain outside of bdrv_root_attach_child()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". The function bdrv_root_attach_child() runs under the graph lock, so it is not allowed to drain. It is called by: 1. blk_insert_bs(), where a

[PULL 21/24] iotests/graph-changes-while-io: add test case with removal of lower snapshot

2025-06-04 Thread Kevin Wolf
From: Andrey Drobyshev This case is catching potential deadlock which takes place when job-dismiss is issued when I/O requests are processed in a separate iothread. See https://mail.gnu.org/archive/html/qemu-devel/2025-04/msg04421.html Signed-off-by: Andrey Drobyshev [FE: re-use top image and

[PULL 06/24] block: mark change_aio_ctx() callback and instances as GRAPH_RDLOCK(_PTR)

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is a small step in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. More concretely, it is in preparation to move the drain out of bdrv_change_aio_context() and marking that function as GRAPH_RDLOCK. Signed-off-by: Fiona Ebner Reviewed-by: Kevin Wolf Message-I

[PULL 04/24] block: move drain outside of read-locked bdrv_inactivate_recurse()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. More granular draining is not trivially possible, because bdrv_inactivate_recurse() can recursively call itself. Signed-off-by: Fiona Ebner Reviewed-by: Kevin Wolf Message-ID: <20250530151125.955508-5-f.e

[PULL 09/24] block: move drain outside of bdrv_try_change_aio_context()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". Convert the function to a _locked() version that has to be called with the graph lock held and add a convenience wrapper that has to be call

[PULL 05/24] block: mark bdrv_parent_change_aio_context() GRAPH_RDLOCK

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is a small step in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. More concretely, it allows marking the change_aio_ctx() callback GRAPH_RDLOCK_PTR, which is the next step. Signed-off-by: Fiona Ebner Reviewed-by: Kevin Wolf Message-ID: <20250530151125.955508

[PULL 03/24] block/snapshot: move drain outside of read-locked bdrv_snapshot_delete()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. More granular draining is not trivially possible, because bdrv_snapshot_delete() can recursively call itself. The return value of bdrv_all_delete_snapshot() changes from -1 to -errno propagated from failed

[PULL 22/24] block/io: remove duplicate GLOBAL_STATE_CODE() in bdrv_do_drained_end()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner Both commit ab61335025 ("block: drain from main loop thread in bdrv_co_yield_to_drain()") and commit d05ab380db ("block: Mark drain related functions GRAPH_RDLOCK") introduced a GLOBAL_STATE_CODE() macro in bdrv_do_drained_end(). The assertion of being in the main thread cannot

[PULL 16/24] block: move drain outside of quorum_del_child()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner The quorum_del_child() callback runs under the graph lock, so it is not allowed to drain. It is only called as the .bdrv_del_child() callback, which is only called in the bdrv_del_child() function, which also runs under the graph lock. The bdrv_del_child() function is called by

[PULL 10/24] block: move drain outside of bdrv_attach_child_common(_abort)()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". The function bdrv_attach_child_common_abort() is used only as the abort callback in bdrv_attach_child_common_drv transactions, so the tran_f

[PULL 17/24] blockdev: drain while unlocked in internal_snapshot_action()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. Signed-off-by: Fiona Ebner Message-ID: <20250530151125.955508-18-f.eb...@proxmox.com> Reviewed-by: Kevin Wolf Signed-off-by: Kevin Wolf --- blockdev.c | 19 +-- 1 file changed, 17 inserti

[PULL 02/24] block: move drain outside of read-locked bdrv_reopen_queue_child()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. More granular draining is not trivially possible, because bdrv_reopen_queue_child() can recursively call itself. Signed-off-by: Fiona Ebner Reviewed-by: Kevin Wolf Message-ID: <20250530151125.955508-3-f.e

[PULL 13/24] block: move drain outside of bdrv_attach_child()

2025-06-04 Thread Kevin Wolf via
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". The function bdrv_attach_child() runs under the graph lock, so it is not allowed to drain. It is called by: 1. replication_start() 2. quorum

[PULL 23/24] iotests: fix 240

2025-06-04 Thread Kevin Wolf
From: Stefan Hajnoczi Commit 2e8e18c2e463 ("virtio-scsi: add iothread-vq-mapping parameter") removed the limitation that virtio-scsi devices must successfully set the AioContext on their BlockBackends. This was made possible thanks to the QEMU multi-queue block layer. This change broke qemu-iote

[PULL 07/24] block: mark bdrv_child_change_aio_context() GRAPH_RDLOCK

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is a small step in preparation to mark bdrv_drained_begin() as GRAPH_UNLOCKED. More concretely, it is in preparation to move the drain out of bdrv_change_aio_context() and marking that function as GRAPH_RDLOCK. Signed-off-by: Fiona Ebner Reviewed-by: Kevin Wolf Message-I

[PULL 11/24] block: move drain outside of bdrv_set_backing_hd_drained()

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner This is part of resolving the deadlock mentioned in commit "block: move draining out of bdrv_change_aio_context() and mark GRAPH_RDLOCK". The function bdrv_set_backing_hd_drained() holds the graph lock, so it is not allowed to drain. It is called by: 1. bdrv_set_backing_hd(), w

[PULL 19/24] block: mark bdrv_drained_begin() and friends as GRAPH_UNLOCKED

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner All of bdrv_drain_all_begin(), bdrv_drain_all() and bdrv_drained_begin() poll and are not allowed to be called with the block graph lock held. Mark the function as such. Suggested-by: Kevin Wolf Signed-off-by: Fiona Ebner Message-ID: <20250530151125.955508-20-f.eb...@proxmox.

[PULL 01/24] block: remove outdated comments about AioContext locking

2025-06-04 Thread Kevin Wolf
From: Fiona Ebner AioContext locking was removed in commit b49f4755c7 ("block: remove AioContext locking"). Signed-off-by: Fiona Ebner Reviewed-by: Kevin Wolf Message-ID: <20250530151125.955508-2-f.eb...@proxmox.com> Signed-off-by: Kevin Wolf --- block.c | 7 --- 1 file changed, 7 deleti

[PULL 00/24] Block layer patches

2025-06-04 Thread Kevin Wolf
The following changes since commit 09be8a511a2e278b45729d7b065d30c68dd699d0: Merge tag 'pull-qapi-2025-06-03' of https://repo.or.cz/qemu/armbru into staging (2025-06-03 09:19:26 -0400) are available in the Git repository at: https://repo.or.cz/qemu/kevin.git tags/for-upstream for you to fe

[PATCH v2 3/3] target/riscv: add profile->present flag

2025-06-04 Thread Daniel Henrique Barboza
Björn reported in [1] a case where a rv64 CPU is going through the profile code path to enable satp mode. In this case,the amount of extensions on top of the rv64 CPU made it compliant with the RVA22S64 profile during the validation of CPU 0. When the subsequent CPUs were initialized the static pro

Re: [PATCH v2 0/3] target/riscv: add missing named features

2025-06-04 Thread Daniel Henrique Barboza
Please disregard this post - some old patches were left in the dir when I pressed "send" ... Thanks, Daniel On 6/4/25 2:37 PM, Daniel Henrique Barboza wrote: Hi, In this version I fixed the problems caused in bios-table-test qtest by patches 1 and 2. A small change was also made in patch 1

  1   2   3   >