Skip to content

soc: rp2350: Exclude image definition block from MCUboot application images #89997

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion soc/raspberrypi/rpi_pico/rp2350/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ config SOC_RP2350B_M33

config RP2_REQUIRES_IMAGE_DEFINITION_BLOCK
bool
default y
default y if FLASH_LOAD_OFFSET = 0x100
# Currently the IDF only supports using the Cortex-M33 cores. Enforce
# this at build configuration time.
depends on SOC_SERIES_RP2350 && CPU_CORTEX_M33
Expand Down
5 changes: 4 additions & 1 deletion soc/raspberrypi/rpi_pico/rp2350/Kconfig.defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@
if SOC_SERIES_RP2350

config BUILD_OUTPUT_UF2_USE_FLASH_BASE
default y if BUILD_OUTPUT_UF2
default y if RP2_REQUIRES_IMAGE_DEFINITION_BLOCK

config BUILD_OUTPUT_UF2_USE_FLASH_OFFSET
default y if !RP2_REQUIRES_IMAGE_DEFINITION_BLOCK

config NUM_IRQS
default 52
Expand Down
7 changes: 7 additions & 0 deletions soc/raspberrypi/rpi_pico/rp2350/linker.ld
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@
* SPDX-License-Identifier: Apache-2.0
*/

/*
* The Image Definition Block is only linked to the app that
* resides at 0x100. This can be the application, or a bootloader
* such as mcuboot.
*/
#if CONFIG_RP2_REQUIRES_IMAGE_DEFINITION_BLOCK
MEMORY
{
IMAGE_DEF_FLASH (r) : ORIGIN = 0x10000000, LENGTH = 128
Expand All @@ -23,5 +29,6 @@ SECTIONS
LONG(0xab123579) /* PICOBIN_BLOCK_MARKER_END */
} > IMAGE_DEF_FLASH
}
#endif /* CONFIG_RP2_REQUIRES_IMAGE_DEFINITION_BLOCK */

#include <zephyr/arch/arm/cortex_m/scripts/linker.ld>
Loading