Page MenuHomePhabricator

With atf-2.9-rc0 “make PLAT=imx8mq bl31” fails with bl31.elf section `.xlat_table' will not fit in region `RAM'
Open, Needs TriagePublic

Description

Build environment is cross compile with gcc-13.1.0 and binutils 2.40
Test builds ok rk3328, rk3399, sun50i_h6, sun50i_a64 are successful

PROJECT=NXP ARCH=arm DEVICE=iMX8 s/build atf
CLEAN      atf
    *      Removing /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.arm-12.0-devel/build/atf-2.8 ...
    *      Removing /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.arm-12.0-devel/qa_checks/atf-* ...
UNPACK      atf
BUILD      atf (target)
    TOOLCHAIN      manual
  CC      lib/libc/abort.c
  CC      lib/libc/assert.c
  CC      lib/libc/exit.c
  CC      lib/libc/memchr.c
  CC      lib/libc/memcmp.c
  CC      lib/libc/memcpy.c
  CC      lib/libc/memmove.c
  CC      lib/libc/memrchr.c
  CC      lib/libc/memset.c
  CC      lib/libc/printf.c
  CC      lib/libc/putchar.c
  CC      lib/libc/puts.c
  CC      lib/libc/snprintf.c
  CC      lib/libc/strchr.c
  CC      lib/libc/strcmp.c
  CC      lib/libc/strlcat.c
  CC      lib/libc/strlcpy.c
  CC      lib/libc/strlen.c
  CC      lib/libc/strncmp.c
  CC      lib/libc/strnlen.c
  CC      lib/libc/strrchr.c
  CC      lib/libc/strtok.c
  CC      lib/libc/strtoul.c
  CC      lib/libc/strtoll.c
  CC      lib/libc/strtoull.c
  CC      lib/libc/strtol.c
  AS      lib/libc/aarch64/setjmp.S
  CC      bl31/bl31_context_mgmt.c
  CC      bl31/bl31_main.c
  CC      bl31/bl31_traps.c
  CC      bl31/interrupt_mgmt.c
  CC      common/runtime_svc.c
  CC      drivers/arm/gic/v3/arm_gicv3_common.c
  CC      drivers/arm/gic/v3/gic-x00.c
  CC      drivers/arm/gic/v3/gicdv3_helpers.c
  CC      drivers/arm/gic/v3/gicrv3_helpers.c
  CC      drivers/arm/gic/v3/gicv3_helpers.c
  CC      drivers/arm/gic/v3/gicv3_main.c
  CC      drivers/arm/tzc/tzc380.c
  CC      drivers/delay_timer/delay_timer.c
  CC      drivers/delay_timer/generic_delay_timer.c
  CC      lib/cpus/errata_report.c
  CC      lib/el3_runtime/aarch64/context_mgmt.c
  CC      lib/el3_runtime/cpu_data_array.c
  CC      lib/extensions/spe/spe.c
  CC      lib/extensions/sve/sve.c
  CC      lib/locks/bakery/bakery_lock_coherent.c
  CC      lib/psci/psci_common.c
  CC      lib/psci/psci_main.c
  CC      lib/psci/psci_mem_protect.c
  CC      lib/psci/psci_off.c
  CC      lib/psci/psci_on.c
  CC      lib/psci/psci_setup.c
  CC      lib/psci/psci_suspend.c
  CC      lib/psci/psci_system_off.c
  CC      lib/xlat_tables_v2/aarch64/xlat_tables_arch.c
  CC      lib/xlat_tables_v2/xlat_tables_context.c
  CC      lib/xlat_tables_v2/xlat_tables_core.c
  CC      lib/xlat_tables_v2/xlat_tables_utils.c
  CC      plat/common/plat_gicv3.c
  CC      plat/common/plat_psci_common.c
  CC      plat/imx/common/imx8_topology.c
  CC      plat/imx/common/imx_sip_handler.c
  CC      plat/imx/common/imx_sip_svc.c
  CC      plat/imx/common/plat_imx8_gic.c
  CC      plat/imx/imx8m/ddr/clock.c
  CC      plat/imx/imx8m/ddr/ddr4_dvfs.c
  CC      plat/imx/imx8m/ddr/dram.c
  CC      plat/imx/imx8m/ddr/dram_retention.c
  CC      plat/imx/imx8m/ddr/lpddr4_dvfs.c
  CC      plat/imx/imx8m/gpc_common.c
  CC      plat/imx/imx8m/imx8m_caam.c
  CC      plat/imx/imx8m/imx8m_psci_common.c
  CC      plat/imx/imx8m/imx8mq/gpc.c
  CC      plat/imx/imx8m/imx8mq/imx8mq_bl31_setup.c
  CC      plat/imx/imx8m/imx8mq/imx8mq_psci.c
  CC      plat/imx/imx8m/imx_aipstz.c
  CC      services/arm_arch_svc/arm_arch_svc_setup.c
  CC      services/std_svc/std_svc_setup.c
  CC      common/bl_common.c
  CC      common/tf_log.c
  CC      drivers/console/multi_console.c
  CC      plat/common/plat_bl_common.c
  CC      plat/common/plat_log_common.c
  CC      plat/common/aarch64/plat_common.c
  CC      lib/compiler-rt/builtins/popcountdi2.c
  CC      lib/compiler-rt/builtins/popcountsi2.c
  AS      bl31/aarch64/bl31_entrypoint.S
  AS      bl31/aarch64/crash_reporting.S
  AS      bl31/aarch64/ea_delegate.S
  AS      bl31/aarch64/runtime_exceptions.S
  AS      lib/cpus/aarch64/cortex_a53.S
  AS      lib/cpus/aarch64/cpu_helpers.S
  AS      lib/cpus/aarch64/dsu_helpers.S
  AS      lib/cpus/aarch64/wa_cve_2017_5715_bpiall.S
  AS      lib/cpus/aarch64/wa_cve_2017_5715_mmu.S
  AS      lib/el3_runtime/aarch64/context.S
  AS      lib/el3_runtime/aarch64/cpu_data.S
  AS      lib/locks/exclusive/aarch64/spinlock.S
  AS      lib/psci/aarch64/psci_helpers.S
  AS      lib/psci/aarch64/runtime_errata.S
  AS      lib/xlat_tables_v2/aarch64/enable_mmu.S
  AS      plat/common/aarch64/platform_mp_stack.S
  AS      plat/imx/common/imx8_helpers.S
  AS      plat/imx/common/imx_uart_console.S
  AS      common/aarch64/debug.S
  AS      lib/aarch64/cache_helpers.S
  AS      lib/aarch64/misc_helpers.S
  AS      plat/common/aarch64/platform_helpers.S
  PP      bl31/bl31.ld.S
  AR      /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.arm-12.0-devel/build/atf-2.9-rc0/build/imx8mq/release/lib/libc.a
  LD      /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.arm-12.0-devel/build/atf-2.9-rc0/build/imx8mq/release/bl31/bl31.elf
aarch64-none-elf-ld.bfd: /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.arm-12.0-devel/build/atf-2.9-rc0/build/imx8mq/release/bl31/bl31.elf section `.xlat_table' will not fit in region `RAM'
aarch64-none-elf-ld.bfd: BL31 image has exceeded its limit.
aarch64-none-elf-ld.bfd: region `RAM' overflowed by 20480 bytes
make: *** [Makefile:1470: /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.arm-12.0-devel/build/atf-2.9-rc0/build/imx8mq/release/bl31/bl31.elf] Error 1
FAILURE: s/build atf during make_target (package.mk)

Event Timeline

heitbaum created this task.May 13 2023, 1:52 PM
heitbaum added a project: Trusted Firmware A.

Fails on 2.9.0

BUILD      atf (target)
    TOOLCHAIN      manual
  LD      /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.aarch64-12.0-devel/build/atf-2.9.0/build/imx8mq/release/bl31/bl31.elf
/var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.aarch64-12.0-devel/toolchain/bin/aarch64-libreelec-linux-gnu-ld.bfd: /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.aarch64-12.0-devel/build/atf-2.9.0/build/imx8mq/release/bl31/bl31.elf section `.xlat_table' will not fit in region `RAM'
/var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.aarch64-12.0-devel/toolchain/bin/aarch64-libreelec-linux-gnu-ld.bfd: BL31 image has exceeded its limit.
/var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.aarch64-12.0-devel/toolchain/bin/aarch64-libreelec-linux-gnu-ld.bfd: region `RAM' overflowed by 20480 bytes
make: *** [Makefile:1470: /var/media/DATA/home-rudi/LibreELEC.kernel11/build.LibreELEC-iMX8.aarch64-12.0-devel/build/atf-2.9.0/build/imx8mq/release/bl31/bl31.elf] Error 1

This issue is introduced with commit dd108c3c1fe3 ("feat(imx8mq): add the dram retention support for imx8mq").

I tested a few toolchains from https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads (10.3, 11.3 and 12.3), all with same result.

This issue is introduced with commit dd108c3c1fe3 ("feat(imx8mq): add the dram retention support for imx8mq").

I tested a few toolchains from https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads geometry dash online (10.3, 11.3 and 12.3), all with same result.

Thanks for this.

Encountering a build issue with bl31 on i.MX8 due to .xlat_table section overflow. Any experiences or guidance on how to address this during the build process?
Best EV Charger Installation Services in Beverly Hills CA

International drift showdown! Join Drift Hunters Unblocked and compete against players worldwide. Are you ready to conquer the global drifting scene?

The music in Geometry Dash is also a big factor. The vibrant electronic music not only inspires but also helps players immerse themselves in every dance step, every jump accurate to the millisecond. A successful level is not only overcoming challenges but also like a dance that is perfectly in sync with the rhythm of the music.