mirror of
https://github.com/apache/nuttx.git
synced 2026-08-14 00:43:13 +00:00
|
Some checks are pending
MemBrowse Memory Report / changes-filter (push) Waiting to run
MemBrowse Memory Report / load-targets (push) Waiting to run
MemBrowse Memory Report / identical (push) Blocked by required conditions
MemBrowse Memory Report / analyze (push) Blocked by required conditions
A protected build on the ESP32 could only use the legacy IDF image format. Kconfig allowed simple boot to be selected with BUILD_PROTECTED, because the legacy format is only a default and not a select, but the result did not link and then did not boot. Simple boot has no second-stage bootloader. __start() maps the flash itself, so everything it reaches must already be in RAM. kernel-space.ld pinned none of it, and it did not place esp32_start at all, so the entry point went to the flash the code was about to map. The chip loaded the RAM segments, jumped to 0x400d0ba4 and took an IllegalInstruction on the first instruction. So this pins the bootloader, flash, ROM, clock and log objects that bootloader_init() and map_rom_segments() reach, along with esp32_start itself, and defines the six _image_* symbols that __start() needs. All of it is behind CONFIG_ESPRESSIF_SIMPLE_BOOT, so a legacy build gets the same IRAM it had before. kernel-space.ld also had no `#include <nuttx/config.h>'. It held no conditionals until now, so nothing showed the omission: the new blocks compiled away silently and the link failed as if the file had not been changed. The default is unchanged. A protected build still selects the legacy format unless the user clears CONFIG_ESP32_APP_FORMAT_LEGACY. Verified on an ESP32-DevKitC V4, ESP32-D0WD-V3 revision 3.1, with esp32-devkitc:knsh and the legacy format turned off. The kernel flashes at 0x1000 and the user image at 0x90000, with no bootloader and no partition table. It maps seven segments, reaches NSH, and runs ostest to the same point as the legacy build. Assisted-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com> |
||
|---|---|---|
| .. | ||
| arm | ||
| arm64 | ||
| avr | ||
| dummy | ||
| hc/m9s12 | ||
| mips | ||
| misoc/lm32/misoc | ||
| or1k/mor1kx/or1k | ||
| renesas | ||
| risc-v | ||
| sim/sim/sim | ||
| sparc | ||
| tricore | ||
| x86/qemu/qemu-i486 | ||
| x86_64/qemu/qemu-intel64 | ||
| xtensa | ||
| z16/z16f/z16f2800100zcog | ||
| z80 | ||
| .gitignore | ||
| Board.mk | ||
| boardctl.c | ||
| CMakeLists.txt | ||
| dummy.c | ||
| Kconfig | ||
| Makefile | ||