Skip to content

zephyr-cp: add ranges; to three rebuilt partitions nodes - #11271

Merged
tannewt merged 1 commit into
adafruit:mainfrom
MakerClassCZ:zephyr-cp-more-ranges
Aug 31, 2026
Merged

zephyr-cp: add ranges; to three rebuilt partitions nodes#11271
tannewt merged 1 commit into
adafruit:mainfrom
MakerClassCZ:zephyr-cp-more-ranges

Conversation

@lynt-smitka

Copy link
Copy Markdown

Follow-up to #11234, which fixed rpi_pico_zephyr. Three more overlays have the same problem.

Measured before and after on stm32wba65i_dk1:

without ranges; with ranges;
boot 0x0 0x08000000
slot0 0x10000 0x08010000
circuitpy 0x108000 0x08108000
storage 0x1e0000 0x081e0000

Each board's own DTS declares ranges; on the partitions node, so this only restores what the overlay dropped. Offsets and sizes are unchanged.

I swept every overlay in the port that rebuilds a partitions node; these three are the only ones affected.

Each of these overlays deletes the partitions node its board DTS declares
and rebuilds it without re-declaring ranges;. Devicetree then leaves the
child addresses untranslated and every partition resolves to a bare offset.

On the two RP2040 boards the code partition lands at 0x100 instead of
0x10000100, so RP2_REQUIRES_SECOND_STAGE_BOOT no longer matches, the second
stage bootloader is not linked in and the UF2 is built for the wrong
address. Same as adafruit#11234, which covered rpi_pico_zephyr.

On stm32wba65i_dk1 the partitions resolve to 0x0, 0x10000, 0x108000 and
0x1e0000 rather than 0x08000000 upwards. flash_map computes a mapped
partition's offset as DT_REG_ADDR(partition) - DT_REG_ADDR(memory), so
every flash_area offset on that board underflows.

Each board's own DTS declares ranges; on that node, so this only puts back
what the overlay dropped. Partition offsets and sizes are unchanged.

@tannewt tannewt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@tannewt
tannewt merged commit e2a318f into adafruit:main Aug 31, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants