[PATCH] xen/arm: Document the erratum #853709 related to Cortex A72

2020-10-14 Thread Michal Orzel
Workaround for Cortex-A57 erratum #852523 is already in Xen but Cortex-A72 erratum #853709 is not although it applies to the same issue. Signed-off-by: Michal Orzel --- docs/misc/arm/silicon-errata.txt | 1 + xen/arch/arm/domain.c| 6 -- 2 files changed, 5 insertions(+), 2

Re: [PATCH] xen/arm: Document the erratum #853709 related to Cortex A72

2020-10-14 Thread Michal Orzel
Hi Julien, I agree. You can update the commit message. Thanks for review. Michal From: Julien Grall Sent: Wednesday, October 14, 2020 12:56 PM To: Michal Orzel ; xen-devel@lists.xenproject.org Cc: Stefano Stabellini ; Volodymyr Babchuk ; Bertrand Marquis

[PATCH] xen/arm: Add workaround for Cortex-A76/Neoverse-N1 erratum #1286807

2020-11-15 Thread Michal Orzel
circumstances TLBI+DSB completes before a read using the translation being invalidated has been observed by other observers. The workaround repeats the TLBI+DSB operation. Signed-off-by: Michal Orzel --- docs/misc/arm/silicon-errata.txt | 2 ++ xen/arch/arm/Kconfig | 18

Re: [PATCH] xen/arm: Add workaround for Cortex-A76/Neoverse-N1 erratum #1286807

2020-11-16 Thread Michal Orzel
On 16.11.2020 11:12, Julien Grall wrote: > Hi Michal, > > On 16/11/2020 07:24, Michal Orzel wrote: >> On the affected Cortex-A76/Neoverse-N1 cores (r0p0 to r3p0), >> if a virtual address for a cacheable mapping of a location is being >> accessed by a core while an

[PATCH v2] xen/arm: Add workaround for Cortex-A76/Neoverse-N1 erratum #1286807

2020-11-16 Thread Michal Orzel
circumstances TLBI+DSB completes before a read using the translation being invalidated has been observed by other observers. The workaround repeats the TLBI+DSB operation for all the TLB flush operations on purpose. Signed-off-by: Michal Orzel --- docs/misc/arm/silicon-errata.txt | 2 ++ xen

Re: [PATCH v2] xen/arm: Add workaround for Cortex-A76/Neoverse-N1 erratum #1286807

2020-11-17 Thread Michal Orzel
Hi Julien, On 17.11.2020 18:30, Julien Grall wrote: > Hi Michal, > > On 16/11/2020 12:11, Michal Orzel wrote: >> On the affected Cortex-A76/Neoverse-N1 cores (r0p0 to r3p0), >> if a virtual address for a cacheable mapping of a location is being >> accessed by a

[PATCH] xen/arm: Fix compilation error when early printk is enabled

2021-01-21 Thread Michal Orzel
rror: constant expression expected at operand 2 -- `ldr x15,=((0x0040+(0)*PAGE_SIZE)+(0x1c09&~PAGE_MASK))` ``` The fix is to include header which now contains definitions for page/size/mask etc. Signed-off-by: Michal Orzel --- xen/include/asm-arm/early_printk.h | 1 + 1 file changed, 1 i

Re: [PATCH] xen/arm: Fix compilation error when early printk is enabled

2021-01-21 Thread Michal Orzel
Hi Jan, On 21.01.2021 10:43, Jan Beulich wrote: > On 21.01.2021 10:30, Michal Orzel wrote: >> Fix compilation error when enabling early printk, introduced >> by commit aa4b9d1ee6538b5cbe218d4d3fcdf9548130a063: >> ``` >> debug.S: Assembler messages: >> debug

[ImageBuilder] Fix device tree node naming

2024-10-21 Thread Michal Orzel
w the device tree spec. 2) dom0 kernel and ramdisk, despite having the reg property do not have unit addresses specified. Fix it. Signed-off-by: Michal Orzel --- scripts/uboot-script-gen | 39 +++ 1 file changed, 23 insertions(+), 16 deletions(-) diff --

[PATCH] device-tree: Move dt-overlay.c to common/device-tree/

2024-10-10 Thread Michal Orzel
: Michal Orzel --- This patch is based on the already acked series (waiting to be committed): https://lore.kernel.org/xen-devel/2024100410.234817-1-michal.or...@amd.com/T/ --- MAINTAINERS | 1 - xen/common/Makefile | 1 - xen/common/device-tree

[PATCH v2 1/6] dt-overlay: Fix NULL pointer dereference

2024-10-04 Thread Michal Orzel
5c2 ("xen/arm: Add XEN_DOMCTL_dt_overlay and device attachment to domains") Signed-off-by: Michal Orzel Reviewed-by: Stefano Stabellini --- Changes in v2: - Add Rb --- xen/common/dt-overlay.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/xen/common/

[PATCH v2 3/6] dt-overlay: Remove ASSERT_UNREACHABLE from add_nodes()

2024-10-04 Thread Michal Orzel
addition functionalities") Signed-off-by: Michal Orzel Reviewed-by: Stefano Stabellini Acked-by: Julien Grall --- Changes in v2: - Add Rb,Ab --- xen/common/dt-overlay.c | 4 1 file changed, 4 deletions(-) diff --git a/xen/common/dt-overlay.c b/xen/common/dt-overlay.c index 8606b14d1e8e.

[PATCH v2 4/6] dt-overlay: Support target-path being root node

2024-10-04 Thread Michal Orzel
path. This makes the attempt to add such device overlay to fail. Signed-off-by: Michal Orzel --- Changes in v2: - Use ?: instead of implicit bool->int conversion --- xen/common/dt-overlay.c | 16 +++- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/xen/common/dt-ov

[PATCH v2 5/6] dt-overlay: Ignore nodes that do not have __overlay__ as their subnode

2024-10-04 Thread Michal Orzel
reduce the number of steps a user needs to do to when it comes to invalid phandles. Fix it by adding checks if overlay < 0 after respective calls to fdt_subnode_offset(). Signed-off-by: Michal Orzel --- Changes in v2: - New patch --- xen/common/dt-overlay.c | 16 ++-- 1 fi

[PATCH v2 2/6] device-tree: Remove __init from unflatten_dt_alloc()

2024-10-04 Thread Michal Orzel
20800c>] dt-overlay.c#handle_add_overlay_nodes+0x290/0x3d4 (XEN)[<0a208360>] dt_overlay_sysctl+0x8c/0x110 (XEN)[<0a27714c>] arch_do_sysctl+0x1c/0x2c Fixes: 9e9d2c079dc4 ("xen/arm/device: Remove __init from function type") Signed-off-by: Michal Orzel Revi

[PATCH v2 6/6] dt-overlay: Print overlay I/O memory ranges in hex

2024-10-04 Thread Michal Orzel
Printing I/O memory rangeset ranges in decimal is not very helpful when debugging, so switch to hex by adding RANGESETF_prettyprint_hex flag for iomem_ranges rangeset. Signed-off-by: Michal Orzel --- Changes in v2: - New patch --- xen/common/dt-overlay.c | 3 ++- 1 file changed, 2 insertions

[PATCH v2 0/6] xen/arm: dt overlay fixes

2024-10-04 Thread Michal Orzel
This series contains fixes and improvements after doing some tests with DT overlay support in Xen. I split the series so that each patch handles a separate issue. Michal Orzel (6): dt-overlay: Fix NULL pointer dereference device-tree: Remove __init from unflatten_dt_alloc() dt-overlay

Re: [PATCH v5 1/3] xen/device-tree: Let DT reserve map entries overlap reserved-memory

2024-11-04 Thread Michal Orzel
On 27/09/2024 00:24, Shawn Anastasio wrote: > > > Commit 53dc37829c31 ("xen/arm: Add DT reserve map regions to > bootinfo.reserved_mem") changes the way reserve map regions are tracked, > and as a result broke bootfdt's ability to handle device trees in which > the reserve map and the `reserve

Re: [PATCH v5 1/3] xen/device-tree: Let DT reserve map entries overlap reserved-memory

2024-11-05 Thread Michal Orzel
On 04/11/2024 13:39, Grygorii Strashko wrote: > > > Hi All, > > On 04.11.24 12:49, Michal Orzel wrote: >> >> >> On 27/09/2024 00:24, Shawn Anastasio wrote: >>> >>> >>> Commit 53dc37829c31 ("xen/arm: Add DT reserve map regions t

Re: [PATCH] xen/device-tree: Allow exact match for overlapping regions

2024-11-13 Thread Michal Orzel
On 13/11/2024 14:50, Julien Grall wrote: > > > Hi Michal, > > On 06/11/2024 15:07, Michal Orzel wrote: >> >> >> On 06/11/2024 14:41, Luca Fancellu wrote: >>> >>> >>> There are some cases where the device tree exposes a memory rang

Re: [PATCH] xen/device-tree: Allow exact match for overlapping regions

2024-11-13 Thread Michal Orzel
On 13/11/2024 15:40, Julien Grall wrote: > > > Hi, > > On 13/11/2024 14:19, Michal Orzel wrote: >> >> >> On 13/11/2024 14:50, Julien Grall wrote: >>> >>> >>> Hi Michal, >>> >>> On 06/11/2024 15:0

Re: [PATCH] xen/device-tree: Allow exact match for overlapping regions

2024-11-13 Thread Michal Orzel
On 13/11/2024 17:41, Julien Grall wrote: > > > Hi, > > On 13/11/2024 15:40, Michal Orzel wrote: >> >> >> On 13/11/2024 15:40, Julien Grall wrote: >>> >>> >>> Hi, >>> >>> On 13/11/2024 14:19, Michal Orzel wrote

Re: [PATCH v2] xen/common: Move gic_preinit() to common code

2024-10-31 Thread Michal Orzel
On 31/10/2024 10:34, Jan Beulich wrote: > > > On 30.10.2024 14:14, Oleksii Kurochko wrote: >> Introduce ic_preinit() in the common codebase, as it is not >> architecture-specific and can be reused by both PPC and RISC-V. >> This function identifies the node with the interrupt-controller proper

Re: [PATCH 3/4] dt-overlay: Remove ASSERT_UNREACHABLE from add_nodes()

2024-09-23 Thread Michal Orzel
Hi Julien, On 20/09/2024 10:35, Julien Grall wrote: > > > Hi Michal, > > On 19/09/2024 12:42, Michal Orzel wrote: >> The assumption stated in the comment that the code will never get there >> is incorrect. It's enough for the target-path to be incorrect (i.e. us

Re: [PATCH 4/4] dt-overlay: Support target-path being root node

2024-09-23 Thread Michal Orzel
On 20/09/2024 05:54, Stefano Stabellini wrote: > > > On Thu, 19 Sep 2024, Michal Orzel wrote: >> Even though in most cases device nodes are not present directly under >> the root node, it's a perfectly valid configuration (e.g. Qemu virt >> machine dtb). At

Re: [PATCH 1/4] dt-overlay: Fix NULL pointer dereference

2024-09-23 Thread Michal Orzel
Hi Julien, On 20/09/2024 10:29, Julien Grall wrote: > > > Hi Michal, > > On 19/09/2024 12:42, Michal Orzel wrote: >> Attempt to attach an overlay (xl dt-overlay attach) to a domain without >> first adding this overlay to Xen (xl dt-overlay add) results in an >&g

Re: [PATCH v3 1/5] xen/livepatch: drop load_addr Elf section field

2024-09-26 Thread Michal Orzel
the exception table. > > No functional change intended. > > Signed-off-by: Roger Pau Monné For Arm part: Acked-by: Michal Orzel ~Michal

Re: [PATCH v4 3/6] xen/arm: use {DT,ACPI}_DEV_INFO for device info sections

2024-09-27 Thread Michal Orzel
= .; > - } :text > + DT_DEV_INFO(.dev.info) > > #ifdef CONFIG_ACPI > - . = ALIGN(8); > - .adev.info : { The name of the section is ".adev.info", but ... > - _asdevice = .; > - *(.adev.info) > - _aedevice = .; > - } :text > + ACPI_DEV_INFO(adev.info) here you're missing the leading dot which will cause the probe to fail. Apart from that: Reviewed-by: Michal Orzel ~Michal

Re: [PATCH v4 6/6] xen/common: move device initialization code to common code

2024-09-27 Thread Michal Orzel
E_XEN_GUEST_HANDLE' >968 | __DEFINE_XEN_GUEST_HANDLE(uint64, uint64_t); > because includes , which in turn includes > "xen.h", which requires to be processed correctly. > Additionally, add to `device.c` as functions from this > header are used within the file. > > Signed-off-by: Oleksii Kurochko > Reviewed-by: Jan Beulich Reviewed-by: Michal Orzel ~Michal

[PATCH 2/4] device-tree: Remove __init from unflatten_dt_alloc()

2024-09-19 Thread Michal Orzel
20800c>] dt-overlay.c#handle_add_overlay_nodes+0x290/0x3d4 (XEN)[<0a208360>] dt_overlay_sysctl+0x8c/0x110 (XEN)[<0a27714c>] arch_do_sysctl+0x1c/0x2c Fixes: 9e9d2c079dc4 ("xen/arm/device: Remove __init from function type") Signed-off-by: Michal Orzel

[PATCH 4/4] dt-overlay: Support target-path being root node

2024-09-19 Thread Michal Orzel
path. This makes the attempt to add such device overlay to fail. Signed-off-by: Michal Orzel --- xen/common/dt-overlay.c | 16 +++- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/xen/common/dt-overlay.c b/xen/common/dt-overlay.c index d18bd12bd38d..63b28889de90 100644

[PATCH 3/4] dt-overlay: Remove ASSERT_UNREACHABLE from add_nodes()

2024-09-19 Thread Michal Orzel
builds. Fixes: 0c0facdab6f5 ("xen/arm: Implement device tree node addition functionalities") Signed-off-by: Michal Orzel --- xen/common/dt-overlay.c | 4 1 file changed, 4 deletions(-) diff --git a/xen/common/dt-overlay.c b/xen/common/dt-overlay.c index 8606b14d1e8e..d18bd12bd38d 1

[PATCH 1/4] dt-overlay: Fix NULL pointer dereference

2024-09-19 Thread Michal Orzel
5c2 ("xen/arm: Add XEN_DOMCTL_dt_overlay and device attachment to domains") Signed-off-by: Michal Orzel --- xen/common/dt-overlay.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/xen/common/dt-overlay.c b/xen/common/dt-overlay.c index d53b4706cd2f..8606b14d1e8

[PATCH 0/4] xen/arm: dt overlay fixes

2024-09-19 Thread Michal Orzel
This series contains fixes after doing some tests with DT overlay support in Xen. I split the series so that each patch fixes a separate issue. Michal Orzel (4): dt-overlay: Fix NULL pointer dereference device-tree: Remove __init from unflatten_dt_alloc() dt-overlay: Remove

Re: [PATCH 1/4] dt-overlay: Fix NULL pointer dereference

2024-09-30 Thread Michal Orzel
Hi Julien, On 30/09/2024 12:37, Julien Grall wrote: > > > On 23/09/2024 12:05, Michal Orzel wrote: >> Hi Julien, > > Hi Michal, > >> On 20/09/2024 10:29, Julien Grall wrote: >>> >>> >>> Hi Michal, >>> >>> On 19/

Re: [PATCH v4] xen: move per-cpu area management into common code

2024-10-02 Thread Michal Orzel
n be executed. That said, by looking at the code I realized that we never call CPU_REMOVE so it is effectively a dead code. As for the change itself: Reviewed-by: Michal Orzel with one question below ... [...] > +static int cf_check cpu_percpu_callback( > +struct notifier_block *nf

Re: [PATCH v4] xen: move per-cpu area management into common code

2024-10-03 Thread Michal Orzel
On 03/10/2024 11:35, oleksii.kuroc...@gmail.com wrote: > > > On Wed, 2024-10-02 at 15:41 +0200, Michal Orzel wrote: >> >> >> On 30/09/2024 18:39, Oleksii Kurochko wrote: >>> >>> >>> Centralize per-cpu area management to reduce c

Re: [PATCH] xen/device-tree: Allow exact match for overlapping regions

2024-11-06 Thread Michal Orzel
On 06/11/2024 14:41, Luca Fancellu wrote: > > > There are some cases where the device tree exposes a memory range > in both /memreserve/ and reserved-memory node, in this case the > current code will stop Xen to boot since it will find that the > latter range is clashing with the already recor

Re: [PATCH v10 04/12] xen/arm: add Dom0 cache coloring support

2024-11-28 Thread Michal Orzel
ing_init(void) > { > -unsigned int way_size; > +unsigned int way_size, i; > > if ( llc_size && llc_nr_ways ) > { > @@ -83,6 +160,9 @@ void __init llc_coloring_init(void) > } else if ( max_nr_colors < 2 ) > panic("Number of LLC colors %u < 2\n", max_nr_colors); > > +for ( i = 0; i < max_nr_colors; i++ ) > +default_colors[i] = i; > + > arch_llc_coloring_init(); > } > > @@ -104,6 +184,43 @@ void domain_dump_llc_colors(const struct domain *d) > print_colors(d->llc_colors, d->num_llc_colors); > } > > +static void __init domain_set_default_colors(struct domain *d) > +{ > +printk(XENLOG_WARNING > + "LLC color config not found for %pd, using all colors\n", d); > + > +d->llc_colors = default_colors; > +d->num_llc_colors = max_nr_colors; > +} > + > +int __init dom0_set_llc_colors(struct domain *d) > +{ > +typeof(*dom0_colors) *colors; > + > +if ( !dom0_num_colors ) > +{ > +domain_set_default_colors(d); > +return 0; > +} > + > +if ( dom0_num_colors > max_nr_colors || NIT: Can we surround dom0_num_colors > max_nr_colors with brackets? Other than that: Reviewed-by: Michal Orzel ~Michal

Re: [PATCH v10 07/12] xen/arm: add support for cache coloring configuration via device-tree

2024-11-28 Thread Michal Orzel
at `docs/man/xl.cfg.pod.5.in`) or via Device Tree, also for Dom0less > +configurations (documentation at `docs/misc/arm/device-tree/booting.txt`) > using NIT: I think you can remove the part "also for Dom0less configurations" if you already mentioned "or via Device Tree". Other than that: Reviewed-by: Michal Orzel ~Michal

Re: [PATCH v10 03/12] xen/arm: permit non direct-mapped Dom0 construction

2024-11-28 Thread Michal Orzel
On 19/11/2024 15:13, Carlo Nonato wrote: > > > Cache coloring requires Dom0 not to be direct-mapped because of its non > contiguous mapping nature, so allocate_memory() is needed in this case. > 8d2c3ab18cc1 ("arm/dom0less: put dom0less feature code in a separate module") > moved allocate_memo

Re: [PATCH v10 01/12] xen/common: add cache coloring common code

2024-11-27 Thread Michal Orzel
On 27/11/2024 14:24, Carlo Nonato wrote: > > > Hi Michal, > > On Wed, Nov 27, 2024 at 11:48 AM Michal Orzel wrote: >> On 19/11/2024 15:13, Carlo Nonato wrote: >>> >>> >>> Last Level Cache (LLC) coloring allows to partition the cache in small

Re: [PATCH v10 02/12] xen/arm: add initial support for LLC coloring on arm64

2024-11-27 Thread Michal Orzel
g the hardware */ > +unsigned int __init get_llc_way_size(void) > +{ > +register_t ccsidr_el1; > +register_t clidr_el1 = READ_SYSREG(CLIDR_EL1); > +register_t csselr_el1 = READ_SYSREG(CSSELR_EL1); > +register_t id_aa64mmfr2_el1 = READ_SYSREG(ID_AA64MMFR2_EL1); > +uint32_t ccsidr_numsets_shift = CCSIDR_NUMSETS_SHIFT; > +uint32_t ccsidr_numsets_mask = CCSIDR_NUMSETS_MASK; > +unsigned int n, line_size, num_sets; > + > +for ( n = CLIDR_CTYPEn_LEVELS; n != 0; n-- ) > +{ > +uint8_t ctype_n = (clidr_el1 >> CLIDR_CTYPEn_SHIFT(n)) & > + CLIDR_CTYPEn_MASK; NIT: align CLIDR_xxx to opening ( Other than that: Reviewed-by: Michal Orzel ~Michal

[PATCH] bootfdt: Unify early printing of memory ranges endpoints

2024-11-19 Thread Michal Orzel
At the moment, when printing memory ranges during early boot, endpoints of some ranges are printed as inclusive (RAM, RESVD, SHMEM) and some as exclusive (Initrd, MODULE). Make the behavior consistent and print all the endpoints as inclusive. Signed-off-by: Michal Orzel --- xen/common/device

Re: [PATCH] bootfdt: Unify early printing of memory ranges endpoints

2024-11-19 Thread Michal Orzel
On 19/11/2024 14:32, Luca Fancellu wrote: > > > Hi Michal, > >> On 19 Nov 2024, at 11:51, Michal Orzel wrote: >> >> At the moment, when printing memory ranges during early boot, endpoints >> of some ranges are printed as inclusive (RAM, RESVD, SHMEM) and

Re: [PATCH v10 01/12] xen/common: add cache coloring common code

2024-11-27 Thread Michal Orzel
-- /dev/null > +++ b/xen/include/xen/llc-coloring.h > @@ -0,0 +1,37 @@ > +/* SPDX-License-Identifier: GPL-2.0-only */ > +/* > + * Last Level Cache (LLC) coloring common header > + * > + * Copyright (C) 2024, Advanced Micro Devices, Inc. > + * Copyright (C) 2024, Minerva Systems SRL > + */ > +#ifndef __COLORING_H__ > +#define __COLORING_H__ > + > +#include You could just forward declare struct domain unless you know you need sched.h for other things too in other patches. > +#include Why is this here? It's not needed yet at this point. > + > +#ifdef CONFIG_LLC_COLORING > +void llc_coloring_init(void); > +void dump_llc_coloring_info(void); > +void domain_dump_llc_colors(const struct domain *d); > +#else > +static inline void llc_coloring_init(void) {} > +static inline void dump_llc_coloring_info(void) {} > +static inline void domain_dump_llc_colors(const struct domain *d) {} > +#endif > + > +unsigned int get_llc_way_size(void); > +void arch_llc_coloring_init(void); > + > +#endif /* __COLORING_H__ */ > + > +/* > + * Local variables: > + * mode: C > + * c-file-style: "BSD" > + * c-basic-offset: 4 > + * tab-width: 4 > + * indent-tabs-mode: nil > + * End: > + */ > diff --git a/xen/include/xen/sched.h b/xen/include/xen/sched.h > index 90666576c2..c0e49cd1e7 100644 > --- a/xen/include/xen/sched.h > +++ b/xen/include/xen/sched.h > @@ -637,6 +637,11 @@ struct domain > > /* Holding CDF_* constant. Internal flags for domain creation. */ > unsigned int cdf; > + > +#ifdef CONFIG_LLC_COLORING > +unsigned int num_llc_colors; > +const unsigned int *llc_colors; > +#endif > }; > > static inline struct page_list_head *page_to_list( > -- > 2.43.0 > Otherwise, with the remarks addressed: Acked-by: Michal Orzel ~Michal

Re: [PATCH] xen/arm32: Get rid of __memzero()

2024-11-27 Thread Michal Orzel
rgmann > Signed-off-by: Nicolas Pitre > Acked-by: Ard Biesheuvel > Acked-by: Arnd Bergmann > Signed-off-by: Russell King > > Origin: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git > ff5fdafc9e97 > Signed-off-by: Julien Grall In case you need Arm's ack apart from Jan's Rb: Acked-by: Michal Orzel ~Michal

Re: [PATCH] kconfig: detect LD implementation

2022-03-16 Thread Michal Orzel
es -fpic cost, if it's available > config CC_HAS_VISIBILITY_ATTRIBUTE > def_bool $(cc-option,-fvisibility=hidden) NIT: You do not really need to use head especiialy if grep for the beginning of a line. With or without this: Reviewed-by: Michal Orzel Cheers, Michal

v2: XTF on arm

2022-03-17 Thread Michal Orzel
Hello, Following up a discussion from the v1 of "XTF on arm" patch series(it's been almost a year), I created a new version with the following major changes: -fixed comments from v1 -no non-MMU environment for arm64 -no PL011 driver -no test-naming/xtf-runner modifications to make OSSTEST happy

[PATCH 1/3] xen: Introduce a header to store common linker scripts content

2022-03-21 Thread Michal Orzel
of them are not yet added/completed in arm linker script but they definitely should be. Please note that this patch does not aim to perform the full sync up between the linker scripts. It creates a base for further work. Signed-off-by: Michal Orzel --- xen/include/xen/xen_lds.h | 114

[PATCH 3/3] xen/arm: Make use of helpers defined in xen_lds.h

2022-03-21 Thread Michal Orzel
d sections, .fini_array which can reference .text.exit -extended list of stabs section to include sections placed by ld.lld. Even though Xen on arm compilation with LLVM support is not ready yet, these sections do not cause problem to GNU ld Signed-off-by: Michal Orzel --- xen/arch/arm/xen.

[PATCH 2/3] xen/x86: Make use of helpers defined in xen_lds.h

2022-03-21 Thread Michal Orzel
Header file xen_lds.h defines common macros to be used in arch specific linker scripts. Include this header and make use of its helpers. Signed-off-by: Michal Orzel --- xen/arch/x86/xen.lds.S | 86 -- 1 file changed, 8 insertions(+), 78 deletions(-) diff

[PATCH 0/3] xen: Linker scripts synchronization

2022-03-21 Thread Michal Orzel
. Michal Orzel (3): xen: Introduce a header to store common linker scripts content x86: Make use of helpers defined in xen_lds.h xen/arm: Make use of helpers defined in xen_lds.h xen/arch/arm/xen.lds.S| 37 - xen/arch/x86/xen.lds.S| 86 +++- xen

Re: [PATCH 1/3] xen: Introduce a header to store common linker scripts content

2022-03-21 Thread Michal Orzel
Hi Jan,   On 21.03.2022 09:21, Michal Orzel wrote: > Both x86 and arm linker scripts share quite a lot of common content. > It is difficult to keep syncing them up, thus introduce a new header > in include/xen called xen_lds.h to store the internals mutual to all > the li

Re: [PATCH 1/3] xen: Introduce a header to store common linker scripts content

2022-03-21 Thread Michal Orzel
nd had to use the non-default one. > On 21.03.2022 11:14, Michal Orzel wrote: >> On 21.03.2022 09:21, Michal Orzel wrote: >>> --- /dev/null >>> +++ b/xen/include/xen/xen_lds.h >>> @@ -0,0 +1,114 @@ >>> +#ifndef __XEN_LDS_H__ >>> +#define __XEN

[PATCH v2 0/2] xen: Linker scripts synchronization

2022-03-22 Thread Michal Orzel
empty header file xen.lds.h to store the constructs mutual to both x86 and arm linker scripts. It also includes this header in the scripts. The second patch populates xen.lds.h with the first portion of common macros and replaces the original contructs with these helpers. Michal Orzel (2): xen

[PATCH v2 1/2] xen: Introduce a header to store common linker scripts content

2022-03-22 Thread Michal Orzel
serves as an intermediate step before populating xen.lds.h and making use of its content in the linker scripts later on. Signed-off-by: Michal Orzel --- Changes since v1: -rename header to xen.lds.h to be coherent with Linux kernel -include empty header in linker scripts --- xen/arch/arm/xen.lds.S

[PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-22 Thread Michal Orzel
or further work. Signed-off-by: Michal Orzel --- Changes since v1: -merge x86 and arm changes into single patch -do not propagate issues by generalizing CTORS -extract sections not related to debugging into separate macro -get rid of _SECTION suffix in favor of using more meaningful suffixes --- xe

Re: [PATCH v4 2/2] gitlab-ci: add an ARM32 qemu-based smoke test

2022-03-23 Thread Michal Orzel
Hi Stefano, On 22.03.2022 21:38, Stefano Stabellini wrote: > Add a minimal ARM32 smoke test based on qemu-system-arm, as provided by > the test-artifacts qemu container. The minimal test simply boots Xen > (built from previous build stages) and Dom0. > > The test needs a working kernel and minima

Re: [RFC PATCH] xen/build: Add cppcheck and cppcheck-html make rules

2022-03-24 Thread Michal Orzel
gt; - CPPCHECK_HTMLREPORT can be used to give the full path to >> cppcheck-htmlreport (default is to use the one from the standard path). >> >> This has been tested on several arm configurations (x86 should work but >> has not been tested). >> >> [1] https://cppche

Re: [RFC PATCH] xen/build: Add cppcheck and cppcheck-html make rules

2022-03-25 Thread Michal Orzel
path). >> - CPPCHECK_HTMLREPORT can be used to give the full path to >> cppcheck-htmlreport (default is to use the one from the standard path). >> >> This has been tested on several arm configurations (x86 should work but >> has not been tested). >> >> [1] ht

Re: [PATCH v2 0/2] xen: Linker scripts synchronization

2022-03-28 Thread Michal Orzel
Hi Jan, Could you please review this series as you did give some comments in v1? On 22.03.2022 09:02, Michal Orzel wrote: > This patch series aims to do the first step towards linker scripts > synchronization. Linker scripts for arm and x86 share a lot of common > sections and in orde

Re: [PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-29 Thread Michal Orzel
Hi Jan, Thanks for review. On 29.03.2022 11:22, Jan Beulich wrote: > On 22.03.2022 09:02, Michal Orzel wrote: >> --- a/xen/arch/arm/xen.lds.S >> +++ b/xen/arch/arm/xen.lds.S >> @@ -69,10 +69,7 @@ SECTIONS >> __proc_info_end = .; >> >> #ifd

Re: [PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-29 Thread Michal Orzel
On 29.03.2022 11:54, Julien Grall wrote: > Hi, > > On 22/03/2022 08:02, Michal Orzel wrote: >> Populate header file xen.lds.h with the first portion of macros storing >> constructs common to x86 and arm linker scripts. Replace the original >> constructs with these h

Re: [PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-29 Thread Michal Orzel
On 29.03.2022 12:54, Julien Grall wrote: > Hi, > > On 29/03/2022 11:12, Michal Orzel wrote: >> On 29.03.2022 11:54, Julien Grall wrote: >>> Hi, >>> >>> On 22/03/2022 08:02, Michal Orzel wrote: >>>> Populate header file xen.lds.h with the fir

Re: [PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-30 Thread Michal Orzel
Hello, On 30.03.2022 12:42, Jan Beulich wrote: > On 30.03.2022 12:32, Julien Grall wrote: >> On 29/03/2022 12:42, Jan Beulich wrote: >>> On 29.03.2022 12:54, Julien Grall wrote: >>>> On 29/03/2022 11:12, Michal Orzel wrote: >>>>> On 29.03.2022 11:54, J

Re: [PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-30 Thread Michal Orzel
On 30.03.2022 13:57, Jan Beulich wrote: > On 30.03.2022 13:04, Michal Orzel wrote: >> Hello, >> >> On 30.03.2022 12:42, Jan Beulich wrote: >>> On 30.03.2022 12:32, Julien Grall wrote: >>>> On 29/03/2022 12:42, Jan Beulich wrote: >>>>>

Re: [PATCH v2 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-30 Thread Michal Orzel
On 30.03.2022 14:53, Jan Beulich wrote: > On 30.03.2022 14:13, Michal Orzel wrote: >> On 30.03.2022 13:57, Jan Beulich wrote: >>> On 30.03.2022 13:04, Michal Orzel wrote: >>>> On 30.03.2022 12:42, Jan Beulich wrote: >>>>> On 30.03.2022 12:32, Julie

[PATCH v3 0/2] xen: Linker scripts synchronization

2022-03-31 Thread Michal Orzel
empty header file xen.lds.h to store the constructs mutual to both x86 and arm linker scripts. It also includes this header in the scripts. The second patch populates xen.lds.h with the first portion of common macros and replaces the original contructs with these helpers. Michal Orzel (2): xen

[PATCH v3 1/2] xen: Introduce a header to store common linker scripts content

2022-03-31 Thread Michal Orzel
serves as an intermediate step before populating xen.lds.h and making use of its content in the linker scripts later on. Signed-off-by: Michal Orzel Acked-by: Jan Beulich --- Changes since v2: -none Changes since v1: -rename header to xen.lds.h to be coherent with Linux kernel -include empty header

[PATCH v3 2/2] xen: Populate xen.lds.h and make use of its macros

2022-03-31 Thread Michal Orzel
rther work. Signed-off-by: Michal Orzel --- Changes since v2: -refactor commit msg -move constructs together with surrounding ifdefery -list constructs other than *_SECTIONS in alphabetical order -add comment about EFI vs EFI support Changes since v1: -merge x86 and arm changes into single pat

Re: [PATCH v3 2/2] xen: Populate xen.lds.h and make use of its macros

2022-04-05 Thread Michal Orzel
Hi Jan, On 05.04.2022 10:49, Jan Beulich wrote: > On 31.03.2022 09:14, Michal Orzel wrote: >> --- a/xen/include/xen/xen.lds.h >> +++ b/xen/include/xen/xen.lds.h >> @@ -5,4 +5,133 @@ >> * Common macros to be used in architecture specific linker scripts. >> *

[PATCH v4 0/2] xen: Linker scripts synchronization

2022-04-05 Thread Michal Orzel
empty header file xen.lds.h to store the constructs mutual to both x86 and arm linker scripts. It also includes this header in the scripts. The second patch populates xen.lds.h with the first portion of common macros and replaces the original contructs with these helpers. Michal Orzel (2): xen

[PATCH v4 1/2] xen: Introduce a header to store common linker scripts content

2022-04-05 Thread Michal Orzel
serves as an intermediate step before populating xen.lds.h and making use of its content in the linker scripts later on. Signed-off-by: Michal Orzel Acked-by: Jan Beulich --- Changes since v2,v3: -none Changes since v1: -rename header to xen.lds.h to be coherent with Linux kernel -include empty

[PATCH v4 2/2] xen: Populate xen.lds.h and make use of its macros

2022-04-05 Thread Michal Orzel
rther work. Signed-off-by: Michal Orzel --- Changes since v3: -use POINTER_ALIGN in debug sections when needed -modify comment about ELF_DETAILS_SECTIONS Changes since v2: -refactor commit msg -move constructs together with surrounding ifdefery -list constructs other than *_SECTIONS in alphabet

Re: [PATCH V2 1/2] xen/arm: Add i.MX lpuart driver

2022-04-06 Thread Michal Orzel
Hi Peng, On 02.04.2022 07:42, Peng Fan (OSS) wrote: > From: Peng Fan > > The i.MX LPUART Documentation: > https://www.nxp.com/webapp/Download?colCode=IMX8QMIEC > Chatper 13.6 Low Power Universal Asynchronous Receiver/ > Transmitter (LPUART) > > Signed-off-by: Peng Fan > --- > xen/drivers/char

Re: [PATCH V2 1/2] xen/arm: Add i.MX lpuart driver

2022-04-06 Thread Michal Orzel
On 06.04.2022 09:39, Peng Fan wrote: >> Subject: Re: [PATCH V2 1/2] xen/arm: Add i.MX lpuart driver >> >> Hi Peng, >> >> On 02.04.2022 07:42, Peng Fan (OSS) wrote: >>> From: Peng Fan >>> >>> The i.MX LPUART Documentation: >>> >> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2F

Re: [PATCH V3 2/2] xen/arm: Add i.MX lpuart early printk support

2022-04-08 Thread Michal Orzel
Hi Peng, On 07.04.2022 04:44, Peng Fan (OSS) wrote: > From: Peng Fan > > Signed-off-by: Peng Fan > --- > xen/arch/arm/Kconfig.debug | 14 +++ > xen/arch/arm/arm64/debug-imx-lpuart.inc | 52 + > xen/arch/arm/include/asm/imx-lpuart.h | 22 +-- >

Re: [PATCH V3 1/2] xen/arm: Add i.MX lpuart driver

2022-04-08 Thread Michal Orzel
Hi Peng, On 07.04.2022 04:44, Peng Fan (OSS) wrote: > From: Peng Fan > > The i.MX LPUART Documentation: > https://www.nxp.com/webapp/Download?colCode=IMX8QMIEC > Chatper 13.6 Low Power Universal Asynchronous Receiver/ > Transmitter (LPUART) > > Tested-by: Henry Wang > Signed-off-by: Peng Fan

Re: [PATCH V4 2/2] xen/arm: Add i.MX lpuart early printk support

2022-04-10 Thread Michal Orzel
Hi Peng, On 08.04.2022 16:09, Peng Fan (OSS) wrote: > From: Peng Fan > > Signed-off-by: Peng Fan > --- > xen/arch/arm/Kconfig.debug | 14 +++ > xen/arch/arm/arm64/debug-imx-lpuart.inc | 52 + > 2 files changed, 66 insertions(+) > create mode 100644 xen

Re: [PATCH V4 1/2] xen/arm: Add i.MX lpuart driver

2022-04-10 Thread Michal Orzel
Hi Peng, On 08.04.2022 16:09, Peng Fan (OSS) wrote: > From: Peng Fan > > The i.MX LPUART Documentation: > https://www.nxp.com/webapp/Download?colCode=IMX8QMIEC > Chatper 13.6 Low Power Universal Asynchronous Receiver/ > Transmitter (LPUART) > > Tested-by: Henry Wang > Signed-off-by: Peng Fan

Re: [PATCH v4 2/2] xen: Populate xen.lds.h and make use of its macros

2022-04-10 Thread Michal Orzel
Hi Julien, On 08.04.2022 19:58, Julien Grall wrote: > Hi Michal, > > On 05/04/2022 10:16, Michal Orzel wrote: >>   #if defined(BUILD_ID) >> @@ -109,12 +104,7 @@ SECTIONS >> *(.data.schedulers) >> __end_schedulers_array = .; >>   -#if

[PATCH v5 0/2] xen: Linker scripts synchronization

2022-04-11 Thread Michal Orzel
empty header file xen.lds.h to store the constructs mutual to both x86 and arm linker scripts. It also includes this header in the scripts. The second patch populates xen.lds.h with the first portion of common macros and replaces the original contructs with these helpers. Michal Orzel (2): xen

[PATCH v5 2/2] xen: Populate xen.lds.h and make use of its macros

2022-04-11 Thread Michal Orzel
ignment in HYPFS_PARAM construct for arm32 from 8 to 4. It is fine as there are no 64bit values used in struct param_hypfs. Please note that this patch does not aim to perform the full sync up between the linker scripts. It creates a base for further work. Signed-off-by: Michal Orzel Review

[PATCH v5 1/2] xen: Introduce a header to store common linker scripts content

2022-04-11 Thread Michal Orzel
serves as an intermediate step before populating xen.lds.h and making use of its content in the linker scripts later on. Signed-off-by: Michal Orzel Acked-by: Jan Beulich --- Changes since v4: -rebased Changes since v2,v3: -none Changes since v1: -rename header to xen.lds.h to be coherent with Linux

Re: [PATCH V4 1/2] xen/arm: Add i.MX lpuart driver

2022-04-11 Thread Michal Orzel
Hi Julien, On 11.04.2022 12:20, Julien Grall wrote: > Hi, > > On 11/04/2022 07:26, Michal Orzel wrote: >> On 08.04.2022 16:09, Peng Fan (OSS) wrote: >>> From: Peng Fan >>> >>> The i.MX LPUART Documentation: >>> https://www.nxp.com/webapp/Do

Re: [PATCH V4 2/2] xen/arm: Add i.MX lpuart early printk support

2022-04-11 Thread Michal Orzel
Hi Julien, On 11.04.2022 12:23, Julien Grall wrote: > Hi, > > On 11/04/2022 07:24, Michal Orzel wrote: >> On 08.04.2022 16:09, Peng Fan (OSS) wrote: >>> From: Peng Fan >>> >>> Signed-off-by: Peng Fan >>> --- >>>   xen/arch/arm/Kcon

Re: [PATCH V5 1/2] xen/arm: Add i.MX lpuart driver

2022-04-14 Thread Michal Orzel
gt; Signed-off-by: Peng Fan Reviewed-by: Michal Orzel Cheers, Michal

Re: [PATCH V5 2/2] xen/arm: Add i.MX lpuart early printk support

2022-04-14 Thread Michal Orzel
On 14.04.2022 09:44, Peng Fan (OSS) wrote: > From: Peng Fan > > Signed-off-by: Peng Fan Reviewed-by: Michal Orzel Cheers, Michal

[PATCH] xen/arm: Make use of DT_MATCH_TIMER in make_timer_node

2022-04-14 Thread Michal Orzel
DT_MATCH_TIMER stores the compatible timer ids and as such should be used in all the places where we need to refer to them. make_timer_node explicitly lists the same ids as the ones defined in DT_MATCH_TIMER so make use of this macro instead. Signed-off-by: Michal Orzel --- xen/arch/arm

Re: [PATCH] xen/arm: Make use of DT_MATCH_TIMER in make_timer_node

2022-04-18 Thread Michal Orzel
Hi Stefano, On 16.04.2022 01:10, Stefano Stabellini wrote: > On Thu, 14 Apr 2022, Michal Orzel wrote: >> DT_MATCH_TIMER stores the compatible timer ids and as such should be >> used in all the places where we need to refer to them. make_timer_node >> explicitly lists the

Re: [PATCH v5 2/2] gitlab-ci: add an ARM32 qemu-based smoke test

2022-04-18 Thread Michal Orzel
Hi Stefano, On 16.04.2022 02:17, Stefano Stabellini wrote: > Add a minimal ARM32 smoke test based on qemu-system-arm, as provided by > the test-artifacts qemu container. The minimal test simply boots Xen > (built from previous build stages) and Dom0. > > The test needs a working kernel and minima

Re: [PATCH V6 2/2] xen/arm: Add i.MX lpuart early printk support

2022-04-18 Thread Michal Orzel
Hi Peng, On 19.04.2022 06:39, Peng Fan (OSS) wrote: > From: Peng Fan > > Signed-off-by: Peng Fan In the v5, I gave you R-by and Bertrand gave A-by so you should have carried them as you haven't done any modificiation in this patch since v5. Anyway, Reviewed-by: Michal Orzel Cheers, Michal

Re: [PATCH V6 1/2] xen/arm: Add i.MX lpuart driver

2022-04-18 Thread Michal Orzel
gt; Signed-off-by: Peng Fan Reviewed-by: Michal Orzel Cheers, Michal

Re: [PATCH v5 2/2] gitlab-ci: add an ARM32 qemu-based smoke test

2022-04-20 Thread Michal Orzel
t; > Instead, use the tiny busybox-based rootfs provided by Alpine Linux, > which is really minimal: just 2.5MB. Note that we cannot use the Alpine > Linux kernel because that doesn't boot on Xen. > > Signed-off-by: Stefano Stabellini Reviewed-by: Michal Orzel Cheers, Michal

[PATCH v2 1/3] xen+tools: Introduce XEN_SYSCTL_PHYSCAP_vpmu

2021-10-06 Thread Michal Orzel
the standard of using separate macro for a flag field. Signed-off-by: Michal Orzel --- tools/golang/xenlight/helpers.gen.go | 2 ++ tools/golang/xenlight/types.gen.go | 1 + tools/include/libxl.h| 6 ++ tools/libs/light/libxl.c | 1 + tools/libs/light/libxl_types

[PATCH v2 0/3] Expose PMU to the guests

2021-10-06 Thread Michal Orzel
physical registers are directly accessible when "vpmu" parameter is enabled in the guest config file. There is no interrupt support and Xen will not save/restore the register values on context switches. This is to be done in the future. Michal Orzel (3): xen+tools: Introduce XEN_SYSCTL_PH

[PATCH v2 3/3] xen: Expose the PMU to the guests

2021-10-06 Thread Michal Orzel
is no interrupt support and Xen will not save/restore the register values on context switches. Please note that this feature is experimental. Signed-off-by: Michal Orzel Signed-off-by: Julien Grall --- docs/man/xl.cfg.5.pod.in | 17 + tools/golang/xenlight

[PATCH v2 2/3] xen/arm: Check for PMU platform support

2021-10-06 Thread Michal Orzel
feature. Add macro cpu_has_pmu to check for PMU support. Signed-off-by: Michal Orzel --- xen/include/asm-arm/cpufeature.h | 49 ++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/xen/include/asm-arm/cpufeature.h b/xen/include/asm-arm/cpufeature.h index

Re: [PATCH v2 1/3] xen+tools: Introduce XEN_SYSCTL_PHYSCAP_vpmu

2021-10-07 Thread Michal Orzel
Hi, On 07.10.2021 09:59, Jan Beulich wrote: > On 06.10.2021 12:58, Michal Orzel wrote: >> Introduce flag XEN_SYSCTL_PHYSCAP_vpmu which >> indicates whether the platform supports vPMU >> functionality. Modify Xen and tools accordingly. >> >> Take the opportunity a

  1   2   3   4   5   6   7   8   9   10   >