xen/arm64: do not (incorrectly) limit size of xenheap
PATCH 1/1 xen/arm64: do not (incorrectly) limit size of xenheap
The commit 88e3ed61642bb393458acc7a9bd2f96edc337190 "x86/NUMA: make init_node_heap() respect Xen heap limit" breaks boot on the arm64 board X-Gene.
The xenheap bits variable is used to know the last RAM MFN always mapped in Xen virtual memory. If the value is 0, it means that all the memory is always mapped in Xen virtual memory.
On X-gene the RAM bank resides above 128GB and last xenheap MFN is 0x4400000. With the new way to calculate the number of bits, xenheap_bits will be equal to 38 bits. This will result to hide all the RAM and the impossibility to allocate xenheap memory.
Given that aarch64 have always all the memory mapped in Xen virtual memory, it's not necessary to call xenheap_max_mfn which set the number of bits.
---
Changes in v2:
- Update the commit title
- Add Ian's acked
--- xen/arch/arm/setup.c | 1 - 1 file changed, 1 deletion(-)
xen/arch/arm/setup.c +0 -1
@@ -665,7 +665,6 @@ static void __init setup_mm(unsigned long dtb_paddr, size_t dtb_size) xenheap_virt_end =XENHEAP_VIRT_START + ram_end - ram_start; xenheap_mfn_start = ram_start >>PAGE_SHIFT ; xenheap_mfn_end = ram_end >>PAGE_SHIFT ; -xenheap_max_mfn (xenheap_mfn_end);/* * Need enough mapped pages for copying the DTB.
Signature · 1 line
2.1.4
Quoted 13 lines · Julien Grall
The commit
88e3ed61642bb393458acc7a9bd2f96edc337190"x86/NUMA: makeinit_node_heap()respect Xen heap limit" breaks boot on the arm64 board X-Gene.The xenheap bits variable is used to know the last RAM MFN always mapped in Xen virtual memory. If the value is 0, it means that all the memory is always mapped in Xen virtual memory.
On X-gene the RAM bank resides above 128GB and last xenheap MFN is
0x4400000. With the new way to calculate the number of bits,xenheap_bitswill be equal to 38 bits. This will result to hide all the RAM and the impossibility to allocate xenheap memory.
Quoted 8 lines
Given that aarch64 have always all the memory mapped in Xen virtual memory, it's not necessary to call
xenheap_max_mfnwhich set the number of bits.Suggested-by Jan Beulich <[email protected]>Signed-off-by Julien Grall <[email protected]>Acked-by Ian Campbell <[email protected]>
Ian Campbell
AppliedQuoted 21 lines · Wei Liu
Quoted 20 lines · Julien Grall
The commit
88e3ed61642bb393458acc7a9bd2f96edc337190"x86/NUMA: makeinit_node_heap()respect Xen heap limit" breaks boot on the arm64 board X-Gene.The xenheap bits variable is used to know the last RAM MFN always mapped
in Xen virtual memory. If the value is 0, it means that all the memory is
always mapped in Xen virtual memory.On X-gene the RAM bank resides above 128GB and last xenheap MFN is
0x4400000. With the new way to calculate the number of bits,xenheap_bits
will be equal to 38 bits. This will result to hide all the RAM and the impossibility to allocate xenheap memory.Given that aarch64 have always all the memory mapped in Xen virtual memory, it's not necessary to call
xenheap_max_mfnwhich set the number of bits.
Quoted 6 lines
Quoted 4 lines
Suggested-by Jan Beulich <[email protected]>Signed-off-by Julien Grall <[email protected]>Acked-by Ian Campbell <[email protected]>Release-acked-by Wei Liu <[email protected]>
Applied.