Forum Discussion
The issue was introduced during the upstreaming process of the Altera Arm Trusted Firmware code (pushing changes from the Altera repositories to the official ATF repos).
The problem resides on the NON_EXECUTABLE attribute assigned to the Linux device tree (with ID NT_FW_CONFIG_ID) in plat/intel/soc/common/bl2_plat_mem_params_desc.c file. The BL31, the Linux kernel and the Linux device tree are part of the FIP file created and the attributes of each one of the components of this file are evaluated as part of BL2 through an assertion and it is expected to be configured as EXECUTABLE. Initially in the Altera source code the device tree was configured as EXECUTABLE to prevent seeing the assertion, but during the upstream process, the community reviewers rejected this assignment requesting to change the configuration as NON_EXECUTABLE.
Note: The assertions in the ATF only works when this is built in debug mode.
The workaround for this problem is to manually update the attributes of the device tree to classify this as EXECUTABLE. This is done by updating the plat/intel/soc/common/bl2_plat_mem_params_desc.c file as follows:
.image_id = NT_FW_CONFIG_ID,
SET_STATIC_PARAM_HEAD(ep_info, PARAM_IMAGE_BINARY,
VERSION_2, entry_point_info_t,
NON_SECURE | NON_EXECUTABLE), <-- Replace this line
NON_SECURE | EXECUTABLE), <-- with this line