Re: [PATCH v1 02/16] arm/vpl011: move DT node parsing to PL011 emulator code

2025-06-25 Thread Orzel, Michal
On 24/06/2025 23:56, dm...@proton.me wrote: > On Tue, Jun 24, 2025 at 09:49:39AM +0200, Orzel, Michal wrote: >> >> >> On 24/06/2025 05:55, dm...@proton.me wrote: >>> From: Denis Mukhin >>> >>> Move vpl011 DT node parsing from common Arm code to PL011 emulator code. >> It's not parsing, it's DT

Re: [PATCH v6 7/8] vpci/msi: Free MSI resources when init_msi() fails

2025-06-25 Thread Chen, Jiqian
On 2025/6/24 18:17, Jan Beulich wrote: > On 24.06.2025 11:49, Chen, Jiqian wrote: >> On 2025/6/18 22:45, Jan Beulich wrote: >>> On 12.06.2025 11:29, Jiqian Chen wrote: --- a/xen/drivers/vpci/msi.c +++ b/xen/drivers/vpci/msi.c @@ -193,6 +193,33 @@ static void cf_check mask_write(

Re: [PATCH v1 05/16] arm/vpl011: use void pointer in domain struct

2025-06-25 Thread Orzel, Michal
On 24/06/2025 05:55, dm...@proton.me wrote: > From: Denis Mukhin > > Switch to using void pointer in domain struct to reduce compile-time > dependencies for PL011 emulator. I don't understand the rationale very well. Could you provide more details? Why can't we keep struct vpl011 in domain st

[PATCH v3 2/3] xen/efi: Support loading initrd using GRUB2 LoadFile2 protocol

2025-06-25 Thread Frediano Ziglio
Allows to load Xen using "linux" and "initrd" GRUB2 commands. This can be used with UKI to separate initrd in a different module instead of bundling all together. Bundling all together can be a problem with Secure Boot where we need to sign the bundle making harder to change it. As initrd content d

Re: [PATCH v6 2/8] vpci: Refactor REGISTER_VPCI_INIT

2025-06-25 Thread Jan Beulich
On 25.06.2025 08:51, Chen, Jiqian wrote: > On 2025/6/24 18:08, Jan Beulich wrote: >> On 24.06.2025 11:29, Chen, Jiqian wrote: >>> On 2025/6/24 16:05, Jan Beulich wrote: On 24.06.2025 10:02, Chen, Jiqian wrote: > On 2025/6/20 14:38, Jan Beulich wrote: >> On 19.06.2025 08:39, Chen, Jiqia

Re: [PATCH 2/4] x86/idle: Remove MFENCEs for CLFLUSH_MONITOR

2025-06-25 Thread Jan Beulich
On 24.06.2025 18:39, Andrew Cooper wrote: > Commit 48d32458bcd4 ("x86, idle: add barriers to CLFLUSH workaround") was > inherited from Linux and added MFENCEs around the AAI65 errata fix. > > The SDM now states: > > Executions of the CLFLUSH instruction are ordered with respect to each > othe

Re: [PATCH v6 2/8] vpci: Refactor REGISTER_VPCI_INIT

2025-06-25 Thread Chen, Jiqian
On 2025/6/25 16:36, Jan Beulich wrote: > On 25.06.2025 08:51, Chen, Jiqian wrote: >> On 2025/6/24 18:08, Jan Beulich wrote: >>> On 24.06.2025 11:29, Chen, Jiqian wrote: On 2025/6/24 16:05, Jan Beulich wrote: > On 24.06.2025 10:02, Chen, Jiqian wrote: >> On 2025/6/20 14:38, Jan Beulich

Re: [PATCH v6 7/8] vpci/msi: Free MSI resources when init_msi() fails

2025-06-25 Thread Chen, Jiqian
On 2025/6/25 17:15, Jan Beulich wrote: > On 25.06.2025 09:16, Chen, Jiqian wrote: >> On 2025/6/24 18:17, Jan Beulich wrote: >>> On 24.06.2025 11:49, Chen, Jiqian wrote: On 2025/6/18 22:45, Jan Beulich wrote: > On 12.06.2025 11:29, Jiqian Chen wrote: >> --- a/xen/drivers/vpci/msi.c

Re: [PATCH 3/4] Revert part of "x86/mwait-idle: disable IBRS during long idle"

2025-06-25 Thread Jan Beulich
On 24.06.2025 18:39, Andrew Cooper wrote: > Most of the patch (handling of CPUIDLE_FLAG_IBRS) is fine, but the > adjustements to mwait_idle() are not. > > spec_ctrl_{enter,exit}_idle() do more than just alter MSR_SPEC_CTRL.IBRS. The > VERW and RSB stuff are **unsafe** to omit. > > The only reaso

Re: [PATCH 4/4] x86/idle: Misc cleanup

2025-06-25 Thread Jan Beulich
On 24.06.2025 18:39, Andrew Cooper wrote: > Sort includes, and drop trailing whitespace. > > No functional change. > > Signed-off-by: Andrew Cooper Acked-by: Jan Beulich

Re: [PATCH v6 4/7] x86: re-work memcpy()

2025-06-25 Thread Jason Andryuk
On 2025-06-16 09:00, Jan Beulich wrote: Move the function to its own assembly file. Having it in C just for the entire body to be an asm() isn't really helpful. Then have two flavors: A "basic" version using qword steps for the bulk of the operation, and an ERMS version for modern hardware, to be

Re: [PATCH v6 7/8] vpci/msi: Free MSI resources when init_msi() fails

2025-06-25 Thread Chen, Jiqian
On 2025/6/25 18:09, Jan Beulich wrote: > On 25.06.2025 11:47, Chen, Jiqian wrote: >> On 2025/6/25 17:15, Jan Beulich wrote: >>> On 25.06.2025 09:16, Chen, Jiqian wrote: On 2025/6/24 18:17, Jan Beulich wrote: > On 24.06.2025 11:49, Chen, Jiqian wrote: >> On 2025/6/18 22:45, Jan Beulich

Re: [PATCH v6 7/7] mm: allow page scrubbing routine(s) to be arch controlled

2025-06-25 Thread Jan Beulich
On 16.06.2025 15:02, Jan Beulich wrote: > --- /dev/null > +++ b/xen/arch/x86/scrub_page.S > @@ -0,0 +1,39 @@ > +.file __FILE__ > + > +#include > +#include > +#include > + > +FUNC(scrub_page_cold) > +mov $PAGE_SIZE/32, %ecx > +mov $SCRUB_PATTERN, %rax > + > +0:

RE: [PATCH] xen/arm: Enhance IPMMU-VMSA driver robustness and debug output

2025-06-25 Thread Jahan Murudi
Hi Michal, Thank you for your review and the Ack. >> +dsb(sy); > Any clue why Linux (mainline) does not do that? The implementation writel() which contains an implicit dsb(st) which likely sufficient for Linux for its Stage-1 IOMMU usage where CPU and IOMMU interactions are coherent. Howe

[PATCH] tools/libxenguest: fix build in stubdom environment

2025-06-25 Thread Juergen Gross
With introduction of the new byteswap infrastructure the build of libxenguest for stubdoms was broken. Fix that again. Fixes: 60dcff871e34 ("xen/decompressors: Remove use of *_to_cpup() helpers") Signed-off-by: Juergen Gross --- tools/libs/guest/xg_dom_decompress_unsafe_lzo1x.c | 9 + to

Re: [PATCH v6 2/8] vpci: Refactor REGISTER_VPCI_INIT

2025-06-25 Thread Chen, Jiqian
On 2025/6/25 18:03, Jan Beulich wrote: > On 25.06.2025 11:27, Chen, Jiqian wrote: >> On 2025/6/25 16:36, Jan Beulich wrote: >>> On 25.06.2025 08:51, Chen, Jiqian wrote: On 2025/6/24 18:08, Jan Beulich wrote: > On 24.06.2025 11:29, Chen, Jiqian wrote: >> On 2025/6/24 16:05, Jan Beulich

Re: [PATCH] tools/libxenguest: fix build in stubdom environment

2025-06-25 Thread Andrew Cooper
On 25/06/2025 11:33 am, Juergen Gross wrote: > With introduction of the new byteswap infrastructure the build of > libxenguest for stubdoms was broken. Fix that again. > > Fixes: 60dcff871e34 ("xen/decompressors: Remove use of *_to_cpup() helpers") > Signed-off-by: Juergen Gross Sorry for breakin

[PATCH] stubdom/grub: avoid relying on start_info definition

2025-06-25 Thread Juergen Gross
The kexec() function of grub-pv is relying on the exact definition of start_info from Mini-OS by having an "#undef start_info" and a few lines later a copy of the Mini-OS definition again. This is bad practice by making all attempts of Mini-OS to change that definition impossible. Avoid that depe

Re: [PATCH 2/4] x86/idle: Remove MFENCEs for CLFLUSH_MONITOR

2025-06-25 Thread Andrew Cooper
On 25/06/2025 10:25 am, Jan Beulich wrote: > On 24.06.2025 18:39, Andrew Cooper wrote: >> Commit 48d32458bcd4 ("x86, idle: add barriers to CLFLUSH workaround") was >> inherited from Linux and added MFENCEs around the AAI65 errata fix. >> >> The SDM now states: >> >> Executions of the CLFLUSH inst

Re: [PATCH 1/4] x86/idle: Move monitor()/mwait() wrappers into cpu-idle.c

2025-06-25 Thread Andrew Cooper
On 25/06/2025 10:19 am, Jan Beulich wrote: > On 24.06.2025 18:39, Andrew Cooper wrote: >> They're not used by any other translation unit, so shouldn't live in >> asm/processor.h, which is included almost everywhere. >> >> Our new toolchain baseline knows the MONITOR/MWAIT instructions, so use them

Re: [PATCH] tools/libxenguest: fix build in stubdom environment

2025-06-25 Thread Jason Andryuk
On 2025-06-25 06:33, Juergen Gross wrote: With introduction of the new byteswap infrastructure the build of libxenguest for stubdoms was broken. Fix that again. Fixes: 60dcff871e34 ("xen/decompressors: Remove use of *_to_cpup() helpers") Signed-off-by: Juergen Gross Reviewed-by: Jason Andryuk

Re: [PATCH v6 7/7] mm: allow page scrubbing routine(s) to be arch controlled

2025-06-25 Thread Jason Andryuk
On 2025-06-25 06:27, Jan Beulich wrote: On 16.06.2025 15:02, Jan Beulich wrote: --- /dev/null +++ b/xen/arch/x86/scrub_page.S @@ -0,0 +1,39 @@ +.file __FILE__ + +#include +#include +#include + +FUNC(scrub_page_cold) +mov $PAGE_SIZE/32, %ecx +mov $SCRUB_PATTERN,

Re: [MINI-OS PATCH] x86/pv: fix breakage of grub-pv build

2025-06-25 Thread Jason Andryuk
On 2025-06-25 07:14, Juergen Gross wrote: grub-pv is relying on start_info being defined, so provide a definition which can be used. Fixes: d669a312b2b2 ("x86/pv: remove global start_info") Signed-off-by: Juergen Gross Reviewed-by: Jason Andryuk

Re: [PATCH] stubdom/grub: avoid relying on start_info definition

2025-06-25 Thread Jason Andryuk
On 2025-06-25 07:08, Juergen Gross wrote: The kexec() function of grub-pv is relying on the exact definition of start_info from Mini-OS by having an "#undef start_info" and a few lines later a copy of the Mini-OS definition again. This is bad practice by making all attempts of Mini-OS to change

Re: [PATCH] stubdom/grub: avoid relying on start_info definition

2025-06-25 Thread Jürgen Groß
On 25.06.25 16:20, Jan Beulich wrote: On 25.06.2025 13:08, Juergen Gross wrote: @@ -432,3 +431,10 @@ out: allocated = 0; xc_interface_close(xc_handle ); } + +static void call_start_info_hook(struct xc_dom_image *dom) +{ +#undef start_info +if ( dom->arch_hooks->start_info ) +

Re: [PATCH] stubdom/grub: avoid relying on start_info definition

2025-06-25 Thread Andrew Cooper
On 25/06/2025 3:28 pm, Jürgen Groß wrote: > On 25.06.25 16:20, Jan Beulich wrote: >> On 25.06.2025 13:08, Juergen Gross wrote: >>> @@ -432,3 +431,10 @@ out: >>>   allocated = 0; >>>   xc_interface_close(xc_handle ); >>>   } >>> + >>> +static void call_start_info_hook(struct xc_dom_image *do

[MINI-OS PATCH] x86/pv: fix breakage of grub-pv build

2025-06-25 Thread Juergen Gross
grub-pv is relying on start_info being defined, so provide a definition which can be used. Fixes: d669a312b2b2 ("x86/pv: remove global start_info") Signed-off-by: Juergen Gross --- arch/x86/setup.c | 1 + include/hypervisor.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/arch/x86/se

Re: [PATCH] xen/arm: Enhance IPMMU-VMSA driver robustness and debug output

2025-06-25 Thread Julien Grall
On 25/06/2025 11:28, Jahan Murudi wrote: Hi Michal, Hi Jahan, Thank you for your review and the Ack. +dsb(sy); Any clue why Linux (mainline) does not do that? One process remark, we typically comment inline rather than pasting a quote and replying at the top of the e-mail. T

[PATCH] xen/arm: Fix booting hwdom/1:1 domU with CONFIG_GRANT_TABLE=n

2025-06-25 Thread Michal Orzel
At the moment, we unconditionally allocate space for grant table region membank and add it in the membanks array to find_unallocated_memory() to find unused memory. In case of CONFIG_GRANT_TABLE=n, the size of the region is empty and assertion in rangeset_remove_range() fails when booting hwdom or

Re: [PATCH] x86/boot: move l_bootmap

2025-06-25 Thread Andrew Cooper
On 25/06/2025 10:05 am, Jan Beulich wrote: > Having them in the general .init.data section is somewhat wasteful, due > to involved padding. Move them into .init.data.page_aligned, and place > that right after .init.bss.stack_aligned. > > Overall .init.data* shrinks by slightly over 2 pages in the b

Re: [PATCH v1] xen: fusa: arch_specs: Definition of the Virtual Machines' roles

2025-06-25 Thread Ayan Kumar Halder
On 23/06/2025 10:34, Yann Sionneau wrote: CAUTION: This message has originated from an External Source. Please use proper judgment and caution when opening attachments, clicking links, or responding to this email. Hi Ayan, Stefano, Hi Yann, This doc looks nice overall! However I do thin

Re: [PATCH 3/4] Revert part of "x86/mwait-idle: disable IBRS during long idle"

2025-06-25 Thread Jan Beulich
On 25.06.2025 15:01, Andrew Cooper wrote: > On 25/06/2025 10:58 am, Jan Beulich wrote: >> On 24.06.2025 18:39, Andrew Cooper wrote: >>> Most of the patch (handling of CPUIDLE_FLAG_IBRS) is fine, but the >>> adjustements to mwait_idle() are not. >>> >>> spec_ctrl_{enter,exit}_idle() do more than jus

Re: [PATCH v6 2/8] vpci: Refactor REGISTER_VPCI_INIT

2025-06-25 Thread Jan Beulich
On 25.06.2025 12:16, Chen, Jiqian wrote: > On 2025/6/25 18:03, Jan Beulich wrote: >> Also, as said - you will need to check whether other architectures are >> different from x86-64 in this regard. We better wouldn't leave a trap here, >> for them to fall into when they enable vPCI support. I.e. my

Re: [PATCH v6 7/8] vpci/msi: Free MSI resources when init_msi() fails

2025-06-25 Thread Jan Beulich
On 25.06.2025 12:26, Chen, Jiqian wrote: > On 2025/6/25 18:09, Jan Beulich wrote: >> On 25.06.2025 11:47, Chen, Jiqian wrote: >>> On 2025/6/25 17:15, Jan Beulich wrote: On 25.06.2025 09:16, Chen, Jiqian wrote: > On 2025/6/24 18:17, Jan Beulich wrote: >> On 24.06.2025 11:49, Chen, Jiqia

Re: [PATCH 3/6] arm/mpu: Populate a new region in Xen MPU mapping table

2025-06-25 Thread Ayan Kumar Halder
Hi Hari, Some questions. On 20/06/2025 10:49, Hari Limaye wrote: CAUTION: This message has originated from an External Source. Please use proper judgment and caution when opening attachments, clicking links, or responding to this email. From: Penny Zheng Introduce map_pages_to_xen() that

Re: [PATCH 1/6] arm/mpu: Find MPU region by range

2025-06-25 Thread Ayan Kumar Halder
Hi, On 20/06/2025 10:49, Hari Limaye wrote: CAUTION: This message has originated from an External Source. Please use proper judgment and caution when opening attachments, clicking links, or responding to this email. From: Luca Fancellu Implement a function to find the index of a MPU region

[PATCH] x86/boot: move l_bootmap

2025-06-25 Thread Jan Beulich
Having them in the general .init.data section is somewhat wasteful, due to involved padding. Move them into .init.data.page_aligned, and place that right after .init.bss.stack_aligned. Overall .init.data* shrinks by slightly over 2 pages in the build I'm looking at. Signed-off-by: Jan Beulich --

Re: [PATCH v6 7/8] vpci/msi: Free MSI resources when init_msi() fails

2025-06-25 Thread Jan Beulich
On 25.06.2025 09:16, Chen, Jiqian wrote: > On 2025/6/24 18:17, Jan Beulich wrote: >> On 24.06.2025 11:49, Chen, Jiqian wrote: >>> On 2025/6/18 22:45, Jan Beulich wrote: On 12.06.2025 11:29, Jiqian Chen wrote: > --- a/xen/drivers/vpci/msi.c > +++ b/xen/drivers/vpci/msi.c > @@ -193,6

[PATCH 0/2] xen/efi: Make boot more flexible, especially with GRUB2

2025-06-25 Thread Frediano Ziglio
The combination of GRUB2, EFI and UKI allows potentially more flexibility. For instance is possible to load xen.efi from a no ESP partition leaving a boot loader like GRUB2 taking care of the file loading. This however requires some changes in Xen to be less restrictive. Specifically for GRUB2 thes

Re: [PATCH v2] xen: Strip xen.efi by default

2025-06-25 Thread Frediano Ziglio
On Thu, Jun 12, 2025 at 11:07 AM Frediano Ziglio wrote: > > For xen.gz file we strip all symbols and have an additional > xen-syms file version with all symbols. > Make xen.efi more coherent stripping all symbols too. > xen.efi.elf can be used for debugging. > > Signed-off-by: Frediano Ziglio > -

[PATCH] x86: don't have gcc over-align data

2025-06-25 Thread Jan Beulich
For (aiui) backwards compatibility reasons, gcc defaults to a mode that was the exclusive one up to gcc4.8, establishing 32-byte alignment for aggregates larger than a certain size. We don't rely on such, and hence we can do with the psABI-compliant 16-byte alignment. Savings in the build I'm look

Re: [PATCH v6 7/8] vpci/msi: Free MSI resources when init_msi() fails

2025-06-25 Thread Jan Beulich
On 25.06.2025 11:47, Chen, Jiqian wrote: > On 2025/6/25 17:15, Jan Beulich wrote: >> On 25.06.2025 09:16, Chen, Jiqian wrote: >>> On 2025/6/24 18:17, Jan Beulich wrote: On 24.06.2025 11:49, Chen, Jiqian wrote: > On 2025/6/18 22:45, Jan Beulich wrote: >> On 12.06.2025 11:29, Jiqian Chen

Re: [PATCH v3 2/2] xen/console: unify printout behavior for UART emulators

2025-06-25 Thread Roger Pau Monné
On Fri, Jun 06, 2025 at 08:11:26PM +, dm...@proton.me wrote: > From: Denis Mukhin > > If virtual UART from domain X prints on the physical console, the behavior is > updated to (see [1]): > - console focus in domain X: do not prefix messages; > - no console focus in domain X: prefix all messa

Re: [PATCH v6 2/8] vpci: Refactor REGISTER_VPCI_INIT

2025-06-25 Thread Jan Beulich
On 25.06.2025 11:27, Chen, Jiqian wrote: > On 2025/6/25 16:36, Jan Beulich wrote: >> On 25.06.2025 08:51, Chen, Jiqian wrote: >>> On 2025/6/24 18:08, Jan Beulich wrote: On 24.06.2025 11:29, Chen, Jiqian wrote: > On 2025/6/24 16:05, Jan Beulich wrote: >> On 24.06.2025 10:02, Chen, Jiqia

Re: [PATCH 3/4] Revert part of "x86/mwait-idle: disable IBRS during long idle"

2025-06-25 Thread Andrew Cooper
On 25/06/2025 10:58 am, Jan Beulich wrote: > On 24.06.2025 18:39, Andrew Cooper wrote: >> Most of the patch (handling of CPUIDLE_FLAG_IBRS) is fine, but the >> adjustements to mwait_idle() are not. >> >> spec_ctrl_{enter,exit}_idle() do more than just alter MSR_SPEC_CTRL.IBRS. >> The >> VERW and

[PATCH] x86/boot: Improve paging mode diagnostics in create_dom0()

2025-06-25 Thread Andrew Cooper
I was presented with this: (XEN) NX (Execute Disable) protection active (XEN) d0 has maximum 416 PIRQs (XEN) (XEN) (XEN) Panic on CPU 0: (XEN) Error creating d0: -95 (XEN) which is less than helpful.

Re: [RFC PATCH v4 5/8] xen/domctl: extend XEN_DOMCTL_assign_device to handle not only iommu

2025-06-25 Thread Jan Beulich
On 25.06.2025 21:56, Oleksii Moisieiev wrote: > > On 23/06/2025 10:15, Jan Beulich wrote: >> On 19.06.2025 18:15, Oleksii Moisieiev wrote: >>> On 18/06/2025 03:04, Stefano Stabellini wrote: On Thu, 12 Jun 2025, Oleksii Moisieiev wrote: >>> diff --git a/xen/arch/arm/firmware/sci.c b/xen/ar

Re: [PATCH v2 4/8] pdx: introduce command line compression toggle

2025-06-25 Thread Jan Beulich
On 25.06.2025 19:45, Roger Pau Monné wrote: > On Wed, Jun 25, 2025 at 06:00:48PM +0200, Jan Beulich wrote: >> On 25.06.2025 17:46, Roger Pau Monné wrote: >>> On Tue, Jun 24, 2025 at 03:40:16PM +0200, Jan Beulich wrote: On 20.06.2025 13:11, Roger Pau Monne wrote: > Introduce a command line

[XEN PATCH] automation/eclair: Make report browsing URL configurable.

2025-06-25 Thread Nicola Vetrini
Currently, the URL where the ECLAIR MISRA C scan reports are saved is hardcoded; making it configurable allows multiple runners and storage servers to be used without resorting to publishing all artifacts to the same report server. Signed-off-by: Alessandro Zucchelli Signed-off-by: Nicola Vetrini

preparations for 4.20.1

2025-06-25 Thread Jan Beulich
All, the release is due in about a week or two. Please point out backports you find missing from the respective staging branch, but which you consider relevant. Jan

Discussion on the delayed start of major frame with ARINC653 scheduler

2025-06-25 Thread Choi, Anderson
We are observing a slight delay in the start of major frame with the current implementation of ARINC653 scheduler, which breaks the determinism in the periodic execution of domains. This seems to result from the logic where the variable "next_major_frame" is calculated based on the current time

Re: [PATCH v2 5/8] pdx: allow per-arch optimization of PDX conversion helpers

2025-06-25 Thread Roger Pau Monné
On Tue, Jun 24, 2025 at 03:51:09PM +0200, Jan Beulich wrote: > On 20.06.2025 13:11, Roger Pau Monne wrote: > > --- /dev/null > > +++ b/xen/arch/x86/include/asm/pdx.h > > @@ -0,0 +1,75 @@ > > +/* SPDX-License-Identifier: GPL-2.0-only */ > > + > > +#ifndef X86_PDX_H > > +#define X86_PDX_H > > + > > +

Re: [PATCH v2 05/17] xen/riscv: introduce things necessary for p2m initialization

2025-06-25 Thread Oleksii Kurochko
On 6/18/25 6:08 PM, Jan Beulich wrote: On 10.06.2025 15:05, Oleksii Kurochko wrote: Introduce the following things: - Update p2m_domain structure, which describe per p2m-table state, with: - lock to protect updates to p2m. - pool with pages used to construct p2m. - clean_pte which indi

Re: [PATCH v2 5/8] pdx: allow per-arch optimization of PDX conversion helpers

2025-06-25 Thread Jan Beulich
On 25.06.2025 17:51, Roger Pau Monné wrote: > On Tue, Jun 24, 2025 at 03:51:09PM +0200, Jan Beulich wrote: >> On 20.06.2025 13:11, Roger Pau Monne wrote: >>> --- /dev/null >>> +++ b/xen/arch/x86/include/asm/pdx.h >>> @@ -0,0 +1,75 @@ >>> +/* SPDX-License-Identifier: GPL-2.0-only */ >>> + >>> +#ifnd

Re: [PATCH] x86/boot: Improve paging mode diagnostics in create_dom0()

2025-06-25 Thread Jan Beulich
On 25.06.2025 17:01, Andrew Cooper wrote: > I was presented with this: > > (XEN) NX (Execute Disable) protection active > (XEN) d0 has maximum 416 PIRQs > (XEN) > (XEN) > (XEN) Panic on CPU 0: > (XEN) Error creating d0: -95 > (XEN) ***

Re: [PATCH v2 8/8] pdx: introduce a new compression algorithm based on region offsets

2025-06-25 Thread Roger Pau Monné
On Tue, Jun 24, 2025 at 06:16:15PM +0200, Jan Beulich wrote: > On 20.06.2025 13:11, Roger Pau Monne wrote: > > With the appearance of Intel Sierra Forest and Granite Rapids it's now > > possible to get a production x86 host with the following memory map: > > > > SRAT: Node 0 PXM 0 [000

Re: [PATCH v2 2/8] kconfig: turn PDX compression into a choice

2025-06-25 Thread Jan Beulich
On 20.06.2025 13:11, Roger Pau Monne wrote: > Rename the current CONFIG_PDX_COMPRESSION to CONFIG_PDX_MASK_COMPRESSION, > and make it part of the PDX compression choice block, in preparation for > adding further PDX compression algorithms. > > No functional change intended as the PDX compression d

Re: [PATCH 4/6] arm/mpu: Destroy an existing entry in Xen MPU memory mapping table

2025-06-25 Thread Ayan Kumar Halder
Hi Hari, On 20/06/2025 10:49, Hari Limaye wrote: CAUTION: This message has originated from an External Source. Please use proper judgment and caution when opening attachments, clicking links, or responding to this email. From: Penny Zheng This commit expands xen_mpumap_update/xen_mpumap_up

Re: [RFC PATCH v4 6/8] xen/arm: scmi: introduce SCI SCMI SMC multi-agent driver

2025-06-25 Thread Oleksii Moisieiev
On 23/06/2025 01:15, Stefano Stabellini wrote: > On Thu, 19 Jun 2025, Oleksii Moisieiev wrote: >> On 18/06/2025 02:22, Stefano Stabellini wrote: >>> On Thu, 12 Jun 2025, Oleksii Moisieiev wrote: [snip] > Are you sure it is worth to go through all this trouble to modify FDT in > place when

Re: [PATCH v2 04/17] xen/riscv: construct the P2M pages pool for guests

2025-06-25 Thread Oleksii Kurochko
On 6/18/25 5:53 PM, Jan Beulich wrote: On 10.06.2025 15:05, Oleksii Kurochko wrote: @@ -18,10 +20,20 @@ struct arch_vcpu_io { struct arch_vcpu { }; +struct paging_domain { +spinlock_t lock; +/* Free P2M pages from the pre-allocated P2M pool */ +struct page_list_head p2m_free

Re: [PATCH] stubdom/grub: avoid relying on start_info definition

2025-06-25 Thread Jürgen Groß
On 25.06.25 16:30, Andrew Cooper wrote: On 25/06/2025 3:28 pm, Jürgen Groß wrote: On 25.06.25 16:20, Jan Beulich wrote: On 25.06.2025 13:08, Juergen Gross wrote: @@ -432,3 +431,10 @@ out:   allocated = 0;   xc_interface_close(xc_handle );   } + +static void call_start_info_hook(stru

Re: [RFC PATCH v4 8/8] docs: armproposa: l to add separate SCMI node for Xen agent

2025-06-25 Thread Oleksii Moisieiev
On 23/06/2025 11:02, Julien Grall wrote: > Hi Stefano and Oleksii, > > Let me start with a bit of process. This is discussion is getting > fairly difficult to follow Can you please trim unrelevant bits > when replying? > > On 22/06/2025 22:57, Stefano Stabellini wrote: >> On Thu, 19 Jun 2025

[PATCH v3 1/3] xen/efi: Handle cases where file didn't come from ESP

2025-06-25 Thread Frediano Ziglio
A boot loader can load files from outside ESP. In these cases device could be not provided or path could be something not supported. In these cases allows to boot anyway, all information could be provided using UKI or using other boot loader features. Signed-off-by: Frediano Ziglio Acked-by: Mare

[PATCH v3 0/3] xen/efi: Make boot more flexible, especially with GRUB2

2025-06-25 Thread Frediano Ziglio
The combination of GRUB2, EFI and UKI allows potentially more flexibility. For instance is possible to load xen.efi from a no ESP partition leaving a boot loader like GRUB2 taking care of the file loading. This however requires some changes in Xen to be less restrictive. Specifically for GRUB2 thes

Re: [PATCH 1/4] x86/idle: Move monitor()/mwait() wrappers into cpu-idle.c

2025-06-25 Thread Jan Beulich
On 24.06.2025 18:39, Andrew Cooper wrote: > They're not used by any other translation unit, so shouldn't live in > asm/processor.h, which is included almost everywhere. > > Our new toolchain baseline knows the MONITOR/MWAIT instructions, so use them > directly rather than using raw hex. > > Chang

Re: [PATCH v2 3/8] pdx: provide a unified set of unit functions

2025-06-25 Thread Roger Pau Monné
On Tue, Jun 24, 2025 at 03:32:23PM +0200, Jan Beulich wrote: > On 20.06.2025 13:11, Roger Pau Monne wrote: > > --- a/xen/arch/arm/setup.c > > +++ b/xen/arch/arm/setup.c > > @@ -255,6 +255,10 @@ void __init init_pdx(void) > > { > > const struct membanks *mem = bootinfo_get_mem(); > > padd

Re: [PATCH v2 4/8] pdx: introduce command line compression toggle

2025-06-25 Thread Jan Beulich
On 25.06.2025 17:46, Roger Pau Monné wrote: > On Tue, Jun 24, 2025 at 03:40:16PM +0200, Jan Beulich wrote: >> On 20.06.2025 13:11, Roger Pau Monne wrote: >>> Introduce a command line option to allow disabling PDX compression. The >>> disabling is done by turning pfn_pdx_add_region() into a no-op,

[PATCH 3/4] Revert part of "x86/mwait-idle: disable IBRS during long idle"

2025-06-25 Thread Andrew Cooper
Most of the patch (handling of CPUIDLE_FLAG_IBRS) is fine, but the adjustements to mwait_idle() are not. spec_ctrl_{enter,exit}_idle() do more than just alter MSR_SPEC_CTRL.IBRS. The VERW and RSB stuff are **unsafe** to omit. The only reason this doesn't need an XSA is because no changes were ma

[PATCH v1 14/16] drivers/vuart: move simple MMIO-based UART emulator

2025-06-25 Thread dmkhn
From: Denis Mukhin Move simple MMIO-based UART emulator under drivers/vuart and rename it to vuart-mmio.c to keep "vuart" for the vUART framework. No functional change intended. Signed-off-by: Denis Mukhin --- xen/arch/arm/Kconfig | 8 xen/arch/arm/Ma

[PATCH v1 13/16] drivers/vuart: move PL011 emulator code

2025-06-25 Thread dmkhn
From: Denis Mukhin Move PL011 emulator to the new location for UART emulators. No functional change intended. Signed-off-by: Denis Mukhin --- xen/arch/arm/Kconfig | 7 --- xen/arch/arm/Makefile | 1 - xen/drivers/Kconfig

Re: [PATCH v6 7/7] mm: allow page scrubbing routine(s) to be arch controlled

2025-06-25 Thread Jason Andryuk
On 2025-06-16 09:02, Jan Beulich wrote: Especially when dealing with large amounts of memory, memset() may not be very efficient; this can be bad enough that even for debug builds a custom function is warranted. We additionally want to distinguish "hot" and "cold" cases (with, as initial heuristi

[PATCH v1 00/16] xen: framework for UART emulators

2025-06-25 Thread dmkhn
The series introduces a driver framework to abstract UART emulators in the hypervisor under drivers/vuart. That allows for architecture-independent handling of virtual UARTs in the console driver and simplifies enabling new UART emulators. The framework is gated by CONFIG_HAS_VUART, which is auto

Re: [PATCH v6 1/8] vpci/header: Emulate extended capability list for dom0

2025-06-25 Thread Jan Beulich
On 24.06.2025 09:01, Chen, Jiqian wrote: > On 2025/6/20 14:29, Jan Beulich wrote: >> On 19.06.2025 04:29, Chen, Jiqian wrote: >>> On 2025/6/18 21:52, Jan Beulich wrote: On 12.06.2025 11:29, Jiqian Chen wrote: > --- a/xen/drivers/vpci/header.c > +++ b/xen/drivers/vpci/header.c > @@

Re: [PATCH v1 13/16] drivers/vuart: move PL011 emulator code

2025-06-25 Thread Jan Beulich
On 24.06.2025 09:31, dm...@proton.me wrote: > On Tue, Jun 24, 2025 at 07:50:33AM +0200, Jan Beulich wrote: >> On 24.06.2025 05:56, dm...@proton.me wrote: >>> From: Denis Mukhin >>> >>> Move PL011 emulator to the new location for UART emulators. >>> >>> No functional change intended. >>> >>> Signed

[PATCH v3 3/3] xen/efi: Update error flow for read_file function

2025-06-25 Thread Frediano Ziglio
Use more explicit goto statements to handle common error code path instead of a lot of if/else. Signed-off-by: Frediano Ziglio --- xen/common/efi/boot.c | 80 +++ 1 file changed, 43 insertions(+), 37 deletions(-) diff --git a/xen/common/efi/boot.c b/xen/c

[PATCH v2 2/2] xen/efi: Support loading initrd using GRUB2 LoadFile2 protocol

2025-06-25 Thread Frediano Ziglio
Allows to load Xen using "linux" and "initrd" GRUB2 commands. This can be used with UKI to separate initrd in a different module instead of bundling all together. Bundling all together can be a problem with Secure Boot where we need to sign the bundle making harder to change it. As initrd content d

Re: [PATCH] xen/efi: Show error message for EFI_INVALID_PARAMETER error

2025-06-25 Thread Marek Marczykowski-Górecki
On Tue, Jun 24, 2025 at 07:35:39AM +0100, Frediano Ziglio wrote: > Show string message instead of code. > This happened trying some different ways to boot Xen, specifically > trying loading xen.efi using GRUB2 "linux" command. > > Signed-off-by: Frediano Ziglio Acked-by: Marek Marczykowski-Górec

Re: [PATCH] stubdom/grub: avoid relying on start_info definition

2025-06-25 Thread Jan Beulich
On 25.06.2025 13:08, Juergen Gross wrote: > @@ -432,3 +431,10 @@ out: > allocated = 0; > xc_interface_close(xc_handle ); > } > + > +static void call_start_info_hook(struct xc_dom_image *dom) > +{ > +#undef start_info > +if ( dom->arch_hooks->start_info ) > +dom->arch_hooks->s

Re: [PATCH v2 04/17] xen/riscv: construct the P2M pages pool for guests

2025-06-25 Thread Jan Beulich
On 25.06.2025 16:48, Oleksii Kurochko wrote: > > On 6/18/25 5:53 PM, Jan Beulich wrote: >> On 10.06.2025 15:05, Oleksii Kurochko wrote: >>> @@ -18,10 +20,20 @@ struct arch_vcpu_io { >>> struct arch_vcpu { >>> }; >>> >>> +struct paging_domain { >>> +spinlock_t lock; >>> +/* Free P2M

Re: [PATCH v10 3/3] xen/domain: use get_initial_domain_id() instead of open-coded 0

2025-06-25 Thread Jan Beulich
On 23.06.2025 20:28, dm...@proton.me wrote: > --- a/xen/common/domain.c > +++ b/xen/common/domain.c > @@ -492,7 +492,7 @@ static int late_hwdom_init(struct domain *d) > struct domain *dom0; > int rv; > > -if ( d != hardware_domain || d->domain_id == 0 ) > +if ( d != hardware_dom

Re: [PATCH 0/2] xen/efi: Make boot more flexible, especially with GRUB2

2025-06-25 Thread Frediano Ziglio
On Tue, Jun 24, 2025 at 9:32 AM Frediano Ziglio wrote: > > The combination of GRUB2, EFI and UKI allows potentially more flexibility. > For instance is possible to load xen.efi from a no ESP partition leaving > a boot loader like GRUB2 taking care of the file loading. > This however requires some

Re: [PATCH 0/2] xen/efi: Make boot more flexible, especially with GRUB2

2025-06-25 Thread Marek Marczykowski-Górecki
On Tue, Jun 24, 2025 at 09:38:42AM +0100, Frediano Ziglio wrote: > On Tue, Jun 24, 2025 at 9:32 AM Frediano Ziglio > wrote: > > > > The combination of GRUB2, EFI and UKI allows potentially more flexibility. > > For instance is possible to load xen.efi from a no ESP partition leaving > > a boot loa

Re: [RFC PATCH v4 8/8] docs: armproposa: l to add separate SCMI node for Xen agent

2025-06-25 Thread Julien Grall
Hi Oleksii, On 25/06/2025 20:47, Oleksii Moisieiev wrote: On 23/06/2025 11:02, Julien Grall wrote: I am probably missing something. But it looks like TF-A requires to suport multi-agent so Xen can use it. Am I correct? Furthermore, I can't tell why the multi-agent support is Xen specific. Sur

Re: [PATCH v2 05/17] xen/riscv: introduce things necessary for p2m initialization

2025-06-25 Thread Jan Beulich
On 25.06.2025 17:31, Oleksii Kurochko wrote: > On 6/18/25 6:08 PM, Jan Beulich wrote: >> On 10.06.2025 15:05, Oleksii Kurochko wrote: >>> @@ -14,6 +18,29 @@ >>> >>> /* Per-p2m-table state */ >>> struct p2m_domain { >>> +/* >>> + * Lock that protects updates to the p2m. >>> + */ >

Re: [PATCH] xen/efi: Do not undefined not defined macro

2025-06-25 Thread Marek Marczykowski-Górecki
On Tue, Jun 24, 2025 at 01:34:59PM +0200, Marek Marczykowski-Górecki wrote: > On Tue, Jun 24, 2025 at 09:33:41AM +0100, Frediano Ziglio wrote: > > On Tue, Jun 24, 2025 at 7:36 AM Frediano Ziglio > > wrote: > > > > > > > Typo on title "Do not undefined not defined macro" -> "Do not undefine > > no

Re: [PATCH] xen/common: Guard freeze/thaw_domains functions with CONFIG_SYSTEM_SUSPEND

2025-06-25 Thread Jan Beulich
On 24.06.2025 08:56, Mykola Kvach wrote: > From: Mykola Kvach > > This patch adds CONFIG_SYSTEM_SUSPEND guards around freeze_domains > and thaw_domains functions. > > This ensures they are only compiled into the hypervisor when the system > suspend functionality is enabled, aligning their inclus

Re: [PATCH v4][PART 1 2/4] xen/arm: Implement PSCI SYSTEM_SUSPEND call for guests

2025-06-25 Thread Mykola Kvach
Hi Michal, On Fri, Jun 13, 2025 at 10:53 AM Orzel, Michal wrote: > > > > On 06/06/2025 05:52, Mykola Kvach wrote: > > Hi, @Julien Grall > > > > On Wed, Jun 4, 2025 at 2:00 AM Julien Grall wrote: > >> > >> Hi Mykola, > >> > >> On 27/05/2025 10:18, Mykola Kvach wrote: > >>> From: Mykola Kvach > >

Re: [PATCH v6 4/8] vpci: Hide extended capability when it fails to initialize

2025-06-25 Thread Chen, Jiqian
On 2025/6/18 22:27, Jan Beulich wrote: > On 12.06.2025 11:29, Jiqian Chen wrote: >> +static int vpci_ext_capability_hide(struct pci_dev *pdev, unsigned int cap) >> +{ >> +const unsigned int offset = pci_find_ext_capability(pdev->sbdf, cap); >> +struct vpci_register *r, *prev_r; >> +stru

Re: [PATCH v2 4/8] pdx: introduce command line compression toggle

2025-06-25 Thread Roger Pau Monné
On Tue, Jun 24, 2025 at 03:40:16PM +0200, Jan Beulich wrote: > On 20.06.2025 13:11, Roger Pau Monne wrote: > > Introduce a command line option to allow disabling PDX compression. The > > disabling is done by turning pfn_pdx_add_region() into a no-op, so when > > attempting to initialize the select

Re: [RFC PATCH v4 5/8] xen/domctl: extend XEN_DOMCTL_assign_device to handle not only iommu

2025-06-25 Thread Oleksii Moisieiev
On 23/06/2025 10:15, Jan Beulich wrote: > On 19.06.2025 18:15, Oleksii Moisieiev wrote: >> On 18/06/2025 03:04, Stefano Stabellini wrote: >>> On Thu, 12 Jun 2025, Oleksii Moisieiev wrote: >> diff --git a/xen/arch/arm/firmware/sci.c b/xen/arch/arm/firmware/sci.c >> index e1522e10e2..8efd541

[PATCH v2 1/2] xen/efi: Handle cases where file didn't come from ESP

2025-06-25 Thread Frediano Ziglio
A boot loader can load files from outside ESP. In these cases device could be not provided or path could be something not supported. In these cases allows to boot anyway, all information could be provided using UKI or using other boot loader features. Signed-off-by: Frediano Ziglio --- Changes si

Re: [PATCH v2 4/8] pdx: introduce command line compression toggle

2025-06-25 Thread Roger Pau Monné
On Wed, Jun 25, 2025 at 06:00:48PM +0200, Jan Beulich wrote: > On 25.06.2025 17:46, Roger Pau Monné wrote: > > On Tue, Jun 24, 2025 at 03:40:16PM +0200, Jan Beulich wrote: > >> On 20.06.2025 13:11, Roger Pau Monne wrote: > >>> Introduce a command line option to allow disabling PDX compression. The

Re: [PATCH v2] xen/efi: Do not undefine not defined macro

2025-06-25 Thread Marek Marczykowski-Górecki
On Tue, Jun 24, 2025 at 12:59:18PM +0100, Frediano Ziglio wrote: > On Tue, Jun 24, 2025 at 12:57 PM Andrew Cooper > wrote: > > > > On 24/06/2025 12:45 pm, Frediano Ziglio wrote: > > > The "buffer" macro is not defined. > > > > > > Fixes: 59e087bf6a9c ("xen/keyhandler: Drop keyhandler_scratch") > >

[PATCH v1 07/16] arm/vuart: rename 'virtual UART' Kconfig option

2025-06-25 Thread dmkhn
From: Denis Mukhin Rename HWDOM_VUART to HAS_VUART_MMIO. This emulator emulates only one register and the use of the emulator is limited to early boot console in the guest OS. No functional change. Signed-off-by: Denis Mukhin --- xen/arch/arm/Kconfig | 2 +- xen/arch/arm/Makefi

Re: [PATCH v1 14/16] drivers/vuart: move simple MMIO-based UART emulator

2025-06-25 Thread Jan Beulich
On 24.06.2025 09:36, dm...@proton.me wrote: > On Tue, Jun 24, 2025 at 07:53:04AM +0200, Jan Beulich wrote: >> On 24.06.2025 05:57, dm...@proton.me wrote: >>> --- a/xen/drivers/vuart/Kconfig >>> +++ b/xen/drivers/vuart/Kconfig >>> @@ -3,6 +3,15 @@ config HAS_VUART >>> >>> if (ARM_32 || ARM_64) >>>

Re: [PATCH v6 2/8] vpci: Refactor REGISTER_VPCI_INIT

2025-06-25 Thread Jan Beulich
On 25.06.2025 12:03, Jan Beulich wrote: > On 25.06.2025 11:27, Chen, Jiqian wrote: >> If I understand correctly, I need to change the definition of >> vpci_capability_t to be: >> >> typedef struct { >> unsigned int id; >> bool is_ext; >> int (* init)(const struct pci_dev *pdev); >>

Re: [PATCH] xen/char: wrap suspend/resume console callbacks with CONFIG_SYSTEM_SUSPEND

2025-06-25 Thread Jan Beulich
On 24.06.2025 11:31, Mykola Kvach wrote: > From: Mykola Kvach > > This patch wraps the suspend/resume console callbacks and related code within > CONFIG_SYSTEM_SUSPEND blocks. This ensures that these functions and their > calls are only included in the build when CONFIG_SYSTEM_SUSPEND is enabled.

Re: [PATCH v2 6/8] test/pdx: add PDX compression unit tests

2025-06-25 Thread Anthony PERARD
On Fri, Jun 20, 2025 at 01:11:28PM +0200, Roger Pau Monne wrote: > +.PHONY: run > +run: $(TARGETS) > +ifeq ($(CC),$(HOSTCC)) > + for test in $? ; do \ > + ./$$test ; \ > + done You need to add `set -e` or the exit value from the tested binary might be ignored. This `run` targe

Re: [PATCH v2] xen/efi: Do not undefine not defined macro

2025-06-25 Thread Andrew Cooper
On 24/06/2025 12:45 pm, Frediano Ziglio wrote: > The "buffer" macro is not defined. > > Fixes: 59e087bf6a9c ("xen/keyhandler: Drop keyhandler_scratch") > Signed-off-by: Frediano Ziglio > Acked-by: Marek Marczykowski-Górecki While correct, the grammar isn't great.  I'd suggest "Drop stale #undef

[PATCH v1 04/16] arm/vpl011: use raw spin_lock_{irqrestore,irqsave}

2025-06-25 Thread dmkhn
From: Denis Mukhin Replace VPL011_{LOCK,UNLOCK} macros with raw spinlock calls to improve readability. No functional change. Signed-off-by: Denis Mukhin --- xen/arch/arm/include/asm/vpl011.h | 4 --- xen/arch/arm/vpl011.c | 50 +++ 2 files changed, 25

  1   2   >