mirror of
https://github.com/apache/nuttx.git
synced 2026-10-02 03:46:25 +00:00
mtd_partition(mtd, firstblock, nblocks) takes the partition offset and size in units of the underlying device "blocks" (geo.blocksize), not erase blocks. Several board drivers accumulated partoffset and computed the partition size in erase-block units and passed them straight to mtd_partition(), so on devices where blocksize != erasesize (W25/SST25: 256B vs 4KB, SAMD5E5 progmem: 512B vs 8KB) every partition came out erasesize/blocksize (16x) too small and misaligned. Convert partoffset and partszbytes to geo.blocksize units at the mtd_partition() call site while keeping the erase-block accumulation. Affected boards: - stm32f103-minimum (W25) - at32f437-mini (W25) - stm32f429i-disco (SST25F064, enabled in the extflash defconfig) - metro-m4 (SAMD5E5 progmem) Also fix pre-existing nxstyle violations in the touched files so the change passes checkpatch (see CONTRIBUTING.md). Assisted-by: DeepSeek Harness:deepseek-v4-flash Signed-off-by: rongbaichuan <rongbaichuan1027@163.com> |
||
|---|---|---|
| .. | ||
| axoloti | ||
| clicker2-stm32 | ||
| common | ||
| mikroe-stm32f4 | ||
| nucleo-f401re | ||
| nucleo-f410rb | ||
| nucleo-f411re | ||
| nucleo-f412zg | ||
| nucleo-f429zi | ||
| nucleo-f446re | ||
| odrive36 | ||
| olimex-stm32-e407 | ||
| olimex-stm32-h405 | ||
| olimex-stm32-h407 | ||
| olimex-stm32-p407 | ||
| omnibusf4 | ||
| stm32f4discovery | ||
| stm32f401rc-rs485 | ||
| stm32f411-minimum | ||
| stm32f411e-disco | ||
| stm32f429i-disco | ||
| stm3240g-eval | ||