|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [XEN RFC PATCH 18/40] xen/arm: Keep memory nodes in dtb for NUMA when boot from EFI
Hi Stefano, On 27/08/2021 00:24, Stefano Stabellini wrote: On Wed, 11 Aug 2021, Wei Chen wrote: Yes. AFAIK, when booting using EFI, the Device-Tree may not contain all the reserved regions. Furthermore, we are still too early to know whether we boot using ACPI and DT. I looked at Linux when I first reviewed this patch because I was wondering what happens if the DT and UEFI map disagrees.I wonder if we should just use device tree for memory and ignore EFI instead. Do you know what Linux does in this regard?
Linux and Xen are the same after this patch:
1) The memory map is coming from UEFI map
2) NUMA ID is coming from the DT
The commit that introduced the change in Linux is:
commit 500899c2cc3e3f06140373b587a69d30650f2d9d
Author: Ard Biesheuvel <ardb@xxxxxxxxxx>
Date: Fri Apr 8 15:50:23 2016 -0700
efi: ARM/arm64: ignore DT memory nodes instead of removing them
There are two problems with the UEFI stub DT memory node removal
routine:
- it deletes nodes as it traverses the tree, which happens to work
but is not supported, as deletion invalidates the node iterator;
- deleting memory nodes entirely may discard annotations in the form
of additional properties on the nodes.
Since the discovery of DT memory nodes occurs strictly before the
UEFI init sequence, we can simply clear the memblock memory table
before parsing the UEFI memory map. This way, it is no longer
necessary to remove the nodes, so we can remove that logic from the
stub as well.
Reviewed-by: Matt Fleming <matt@xxxxxxxxxxxxxxxxxxx>
Acked-by: Steve Capper <steve.capper@xxxxxxx>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@xxxxxxxxxx>
Signed-off-by: David Daney <david.daney@xxxxxxxxxx>
Signed-off-by: Will Deacon <will.deacon@xxxxxxx>
Cheers,
--
Julien Grall
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |