Skip to content

Commit 4cebced

Browse files
jholfabiobaltieri
authored andcommitted
doc: kernel: code-relocation: Document NOINIT memory type
The `zephyr_code_relocate` now supports the NOINIT memory type in addition to DATA, TEXT and BSS. This patch documents its usage. Signed-off-by: Joel Holdsworth <jholdsworth@nvidia.com>
1 parent 56e5121 commit 4cebced

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

doc/kernel/code-relocation.rst

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,17 +84,18 @@ This section shows additional configuration options that can be set in
8484
zephyr_code_relocate(FILES src/file1.c LOCATION SRAM2)
8585
zephyr_code_relocate(FILES src/file2.c LOCATION SRAM)
8686
87-
* If the memory type is appended with ``_DATA``, ``_TEXT``, ``_RODATA`` or
88-
``_BSS``, only the selected memory is placed in the required memory region.
89-
For example:
87+
* If the memory type is appended with ``_DATA``, ``_TEXT``, ``_RODATA``,
88+
``_BSS`` or ``_NOINIT``, only the selected memory is placed in the required
89+
memory region. For example:
9090

9191
.. code-block:: none
9292
9393
zephyr_code_relocate(FILES src/file1.c LOCATION SRAM2_DATA)
9494
zephyr_code_relocate(FILES src/file2.c LOCATION SRAM2_TEXT)
9595
96-
* Multiple regions can also be appended together such as: ``SRAM2_DATA_BSS``.
97-
This will place data and bss inside ``SRAM2``.
96+
* Multiple regions can also be appended together such as:
97+
``SRAM2_DATA_BSS_NOINIT``. This will place all data: value-initialized,
98+
zero-initialized and uninitialized inside ``SRAM2``.
9899

99100
* Multiple files can be passed to the ``FILES`` argument, or CMake generator
100101
expressions can be used to relocate a comma-separated list of files.

0 commit comments

Comments
 (0)