Skip to content
Commit 98b8f30a authored by Bradley Bolen's avatar Bradley Bolen Committed by Christopher Friedt
Browse files

boards: qemu_cortex_r5: Disable compiling with thumb mode



Thumb/ARM interworking causes problems with Zephyr's multiple link build
process when userspace is enabled.  When compiling with userspace, the
first link process uses a dummy PROVIDE in the linker script for
z_object_find and z_object_wordlist_foreach.  This dummy symbol is
treated as an ARM function call, but one of the calling functions is in
thumb mode.  The compiler generates a veneer for thumb functions to call
z_object_wordlist_foreach.  On the final link step, z_object_find and
z_object_wordlist_foreach are real functions and get compiled in thumb
mode, thus no veneer is generated in the text section.  This means that
the .text size changes between the second and third link steps changing
the start of the devices section.  That causes the kobject code to look
in the wrong spot for kernel objects and a crash ensues.

Workaround this for now by only compiling in ARM mode so that no veneer
is needed.  Thus the section sizes stay the same during the different
linking steps.

Signed-off-by: default avatarBradley Bolen <bbolen@lexmark.com>
parent d91e4a52
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment