
For the latest kernel device tree the max number of reserved regions in lmb library is reached: 8 with 5 reserved regions in device tree.
When a new region is added, the lmb allocation for the device tree relocation failed and boot with ramdisk failed.
This patch avoids this issue by increasing the max number of supported reserved memory in lmb library to 16.
Signed-off-by: Patrick Delaunay patrick.delaunay@foss.st.com ---
Changes in v2: - Add CONFIG_LMB_USE_MAX_REGIONS=n and reduce LMB_MEMORY_REGIONS to reduce the used size in stack
configs/stm32mp15_basic_defconfig | 3 +++ configs/stm32mp15_trusted_defconfig | 3 +++ 2 files changed, 6 insertions(+)
diff --git a/configs/stm32mp15_basic_defconfig b/configs/stm32mp15_basic_defconfig index 1c680984b8..a290224a46 100644 --- a/configs/stm32mp15_basic_defconfig +++ b/configs/stm32mp15_basic_defconfig @@ -168,3 +168,6 @@ CONFIG_WDT_STM32MP=y CONFIG_ERRNO_STR=y # CONFIG_HEXDUMP is not set CONFIG_FDT_FIXUP_PARTITIONS=y +# CONFIG_LMB_USE_MAX_REGIONS is not set +CONFIG_LMB_MEMORY_REGIONS=2 +CONFIG_LMB_RESERVED_REGIONS=16 diff --git a/configs/stm32mp15_trusted_defconfig b/configs/stm32mp15_trusted_defconfig index 107041119f..ebd4c05891 100644 --- a/configs/stm32mp15_trusted_defconfig +++ b/configs/stm32mp15_trusted_defconfig @@ -148,3 +148,6 @@ CONFIG_WDT_STM32MP=y CONFIG_ERRNO_STR=y # CONFIG_HEXDUMP is not set CONFIG_FDT_FIXUP_PARTITIONS=y +# CONFIG_LMB_USE_MAX_REGIONS is not set +CONFIG_LMB_MEMORY_REGIONS=2 +CONFIG_LMB_RESERVED_REGIONS=16