-
Notifications
You must be signed in to change notification settings - Fork 7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
zephyr_code_relocate() now supports the NOCOPY_DATA flag to inhibit data relocation #86628
base: main
Are you sure you want to change the base?
Conversation
Hello @rhaberkorn, and thank you very much for your first pull request to the Zephyr project! |
This is activated by passing NOCOPY_DATA to zephyr_code_relocate(). It helps when building firmwares for coprocessors, where the image is loaded completely into SRAM from Linux-land using the remoteproc framework. Fixes: zephyrproject-rtos#86530 Signed-off-by: Robin Haberkorn <haberkorn@metratec.com>
c2c7015
to
1118aa3
Compare
@@ -149,14 +149,18 @@ XIP area. | |||
|
|||
This example will place the .text section of the ``xip_external_flash.c`` file | |||
to the ``EXTFLASH`` memory region where it will be executed from (XIP). The | |||
.data will be relocated as usual into SRAM. | |||
.data will be relocated as usual into SRAM, since XIP flash does not |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.data will be relocated as usual into SRAM, since XIP flash does not | |
.data will be relocated as usual into SRAM, since Flash in XIP mode does not |
@@ -149,14 +149,18 @@ XIP area. | |||
|
|||
This example will place the .text section of the ``xip_external_flash.c`` file | |||
to the ``EXTFLASH`` memory region where it will be executed from (XIP). The | |||
.data will be relocated as usual into SRAM. | |||
.data will be relocated as usual into SRAM, since XIP flash does not | |||
allow random write access and variables do not have to be persisted. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
allow random write access and variables do not have to be persisted. | |
allow random write access and variables do not have to persist. |
This helps when building firmwares for coprocessors, where the image is loaded completely into SRAM in Linux-land using the remoteproc framework.
For a motivation of this change, see #86530.