zephyr/samples/boards/intel_adsp/code_relocation/README.rst
Ederson de Souza 7ffc6c31b5 samples/boards: Add intel_adsp/code_relocation sample
A simple sample with some (explained) tricks to get code relocation for
Intel ADSP CAVS platforms.

Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
2022-11-03 10:25:07 +01:00

37 lines
865 B
ReStructuredText

.. _intel_adsp_code_relocation:
Intel ADSP CAVS Code relocation
###############################
Overview
********
A simple sample that shows code relocation working for Intel ADSP CAVS
boards (v18 and v25). The interesting bit is the custom linker file.
As rimage (the tool used to sign the image) mandates that elf files
sections TEXT, DATA and BSS be contiguous, some work is done in the
linker script to ensure that.
Building and Running
********************
This application can be built and executed on QEMU as follows:
.. zephyr-app-commands::
:zephyr-app: samples/hello_world
:board: intel_adsp_cavs25
:goals: build
:compact:
Sample Output
=============
.. code-block:: console
main location: 0xbe0105e4
Calling relocated code
Relocated code! reloc location 0xbe008010
maybe_bss location: 0x9e004218 maybe_bss value: 0