Open adamliyi opened 2 years ago
The upstream proposal to increase the MEMBLOCK_INIT_REGIONS is heading in a good direction. The suggestion to do this automatically for arm64 EFI systems makes sense and should avoid the need to coordinate a config default change with all the distros. Will continue to monitor and engage upstream as required.
v2 of this patch is undergoing review: https://lore.kernel.org/all/20220517114309.10228-1-zhouguanghui1@huawei.com/
Root Cause: During UEFI boot, the system creates a memory map of the memory region used by UEFI. This memory map region is presented to the OS kernel at boot time. Linux kernel will parse this memory map and create its own entry into disjoint regions for its use. At the moment, the Linux kernel supports only up to 128 boot-time disjoint regions. In the event there is more than 128, the Linux kernel will panic. The number of UEFI memory regions created can vary based on the number of PCIe cards and individual driver capabilities of each card.
track bugzilla 97690 I believe this is a kernel issue. See this URL - https://lore.kernel.org/linux-mm/YnypGu1Cu2xPQ1nA@kernel.org/T/
It seems to be observed by other vendor as well.
INIT_MEMBLOCK_REGIONS is limited to 128. It looks like at time UEFI seem to allocated more than 128. In such case, OS will failed. OS vendor should pull in this above patch and increase it.