Re: [PATCH v2 2/4] tools: Import standalone sd_notify() implementation from systemd

2024-05-23 Thread Jürgen Groß
On 16.05.24 20:58, Andrew Cooper wrote: ... in order to avoid linking against the whole of libsystemd. Only minimal changes to the upstream copy, to function as a drop-in replacement for sd_notify() and as a header-only library. Signed-off-by: Andrew Cooper With s/cleanup(sd_closep)/cleanup(

Re: [PATCH] x86/shadow: don't leave trace record field uninitialized

2024-05-23 Thread Oleksii K.
On Wed, 2024-05-22 at 12:17 +0200, Jan Beulich wrote: > The emulation_count field is set only conditionally right now. > Convert > all field setting to an initializer, thus guaranteeing that field to > be > set to 0 (default initialized) when GUEST_PAGING_LEVELS != 3. > > While there also drop the

Re: [for-4.19] Re: [XEN PATCH v3] arm/mem_access: add conditional build of mem_access.c

2024-05-23 Thread Oleksii K.
Hi Julien, On Wed, 2024-05-22 at 21:50 +0100, Julien Grall wrote: > Hi, > > Adding Oleksii as the release manager. > > On 22/05/2024 19:27, Tamas K Lengyel wrote: > > On Fri, May 10, 2024 at 8:32 AM Alessandro Zucchelli > > wrote: > > > > > > In order to comply to MISRA C:2012 Rule 8.4 for ARM

Re: [PATCH v16 5/5] xen/arm: account IO handlers for emulated PCI MSI-X

2024-05-23 Thread Roger Pau Monné
On Wed, May 22, 2024 at 06:59:24PM -0400, Stewart Hildebrand wrote: > From: Oleksandr Andrushchenko > > At the moment, we always allocate an extra 16 slots for IO handlers > (see MAX_IO_HANDLER). So while adding IO trap handlers for the emulated > MSI-X registers we need to explicitly tell that w

Re: [PATCH v16 1/5] arm/vpci: honor access size when returning an error

2024-05-23 Thread Roger Pau Monné
On Wed, May 22, 2024 at 06:59:20PM -0400, Stewart Hildebrand wrote: > From: Volodymyr Babchuk > > Guest can try to read config space using different access sizes: 8, > 16, 32, 64 bits. We need to take this into account when we are > returning an error back to MMIO handler, otherwise it is possibl

Re: [PATCH v16 4/5] xen/arm: translate virtual PCI bus topology for guests

2024-05-23 Thread Roger Pau Monné
On Wed, May 22, 2024 at 06:59:23PM -0400, Stewart Hildebrand wrote: > From: Oleksandr Andrushchenko > > There are three originators for the PCI configuration space access: > 1. The domain that owns physical host bridge: MMIO handlers are > there so we can update vPCI register handlers with the v

Re: [PATCH v6 7/8] xen: mapcache: Add support for grant mappings

2024-05-23 Thread Manos Pitsidianakis
On Thu, 16 May 2024 18:48, "Edgar E. Iglesias" wrote: From: "Edgar E. Iglesias" Add a second mapcache for grant mappings. The mapcache for grants needs to work with XC_PAGE_SIZE granularity since we can't map larger ranges than what has been granted to us. Like with foreign mappings (xen_memo

[PATCH v4 6/9] xen/arm/gic: Allow removing interrupt to running VMs

2024-05-23 Thread Henry Wang
From: Vikram Garhwal Currently, removing physical interrupts are only allowed at the domain destroy time. For use cases such as dynamic device tree overlay removing, the removing of physical IRQ to running domains should be allowed. Move the above-mentioned domain dying check to vgic_connect_hw_

[PATCH v4 8/9] tools: Introduce the "xl dt-overlay {attach,detach}" commands

2024-05-23 Thread Henry Wang
With the XEN_DOMCTL_dt_overlay DOMCTL added, users should be able to attach/detach devices from the provided DT overlay to domains. Support this by introducing a new set of "xl dt-overlay" commands and related documentation, i.e. "xl dt-overlay {attach,detach}". Slightly rework the command option p

[PATCH v4 5/9] xen/arm: Add XEN_DOMCTL_dt_overlay and device attachment to domains

2024-05-23 Thread Henry Wang
In order to support the dynamic dtbo device assignment to a running VM, the add/remove of the DT overlay and the attach/detach of the device from the DT overlay should happen separately. Therefore, repurpose the existing XEN_SYSCTL_dt_overlay to only add the DT overlay to Xen device tree, instead o

[PATCH v4 9/9] docs: Add device tree overlay documentation

2024-05-23 Thread Henry Wang
From: Vikram Garhwal Signed-off-by: Vikram Garhwal Signed-off-by: Stefano Stabellini Signed-off-by: Henry Wang --- v4: - No change. v3: - No change. v2: - Update the content based on the changes in this version. --- docs/misc/arm/overlay.txt | 99 +++ 1 fil

[PATCH v4 1/9] tools/xl: Correct the help information and exit code of the dt-overlay command

2024-05-23 Thread Henry Wang
Fix the name mismatch in the xl dt-overlay command, the command name should be "dt-overlay" instead of "dt_overlay". Add the missing "," in the cmdtable. Fix the exit code of the dt-overlay command, use EXIT_FAILURE instead of ERROR_FAIL. Fixes: 61765a07e3d8 ("tools/xl: Add new xl command overlay

[PATCH v4 3/9] tools/arm: Introduce the "nr_spis" xl config entry

2024-05-23 Thread Henry Wang
Currently, the number of SPIs allocated to the domain is only configurable for Dom0less DomUs. Xen domains are supposed to be platform agnostics and therefore the numbers of SPIs for libxl guests should not be based on the hardware. Introduce a new xl config entry for Arm to provide a method for u

[PATCH v4 7/9] xen/arm: Support device detachment from domains

2024-05-23 Thread Henry Wang
Similarly as the device attachment from DT overlay to domain, this commit implements the device detachment from domain. The DOMCTL XEN_DOMCTL_dt_overlay op is extended to have the operation XEN_DOMCTL_DT_OVERLAY_DETACH. The detachment of the device is implemented by unmapping the IRQ and IOMMU reso

[PATCH v4 4/9] xen/arm/gic: Allow adding interrupt to running VMs

2024-05-23 Thread Henry Wang
Currently, adding physical interrupts are only allowed at the domain creation time. For use cases such as dynamic device tree overlay addition, the adding of physical IRQ to running domains should be allowed. Drop the above-mentioned domain creation check. Since this will introduce interrupt state

[PATCH v4 2/9] xen/arm, doc: Add a DT property to specify IOMMU for Dom0less domUs

2024-05-23 Thread Henry Wang
There are some use cases in which the dom0less domUs need to have the XEN_DOMCTL_CDF_iommu set at the domain construction time. For example, the dynamic dtbo feature allows the domain to be assigned a device that is behind the IOMMU at runtime. For these use cases, we need to have a way to specify

[PATCH v4 0/9] Remaining patches for dynamic node programming using overlay dtbo

2024-05-23 Thread Henry Wang
Hi all, This is the remaining series for the full functional "dynamic node programming using overlay dtbo" feature. The first part [1] has already been merged. Quoting from the original series, the first part has already made Xen aware of new device tree node which means updating the dt_host with

Re: [PATCH v16 3/5] vpci: add initial support for virtual PCI bus topology

2024-05-23 Thread Roger Pau Monné
On Wed, May 22, 2024 at 06:59:22PM -0400, Stewart Hildebrand wrote: > From: Oleksandr Andrushchenko > > Assign SBDF to the PCI devices being passed through with bus 0. > The resulting topology is where PCIe devices reside on the bus 0 of the > root complex itself (embedded endpoints). > This impl

Re: [PATCH] docs/misra: rules for mass adoption

2024-05-23 Thread Jan Beulich
On 23.05.2024 03:26, Stefano Stabellini wrote: > @@ -725,12 +787,25 @@ maintainers if you want to suggest a change. > - The Standard Library function system of shall not be used > - > > + * - `Rule 22.1 >

<    1   2