Commit b7967f7
samples: drivers: spi_flash: Use valid addresses/sizes for dual-flash
When a board contains two identical flash memories configured in
parallel dual-flash mode, the actual sector size is twice the sector
size of a single flash memory. So, assuming 4-KiB sectors for each flash
memory, any erase operation must be 8-KiB aligned.
This commit updates the start offset and sector size in the spi_flash
sample to be properly aligned when a dual-flash configuration is used.
At the moment, this is only supported for STM32-based boards and QSPI
flash memories.
Signed-off-by: Thomas Altenbach <[email protected]>1 parent 513073b commit b7967f7
1 file changed
+4
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
| 27 | + | |
26 | 28 | | |
27 | 29 | | |
28 | 30 | | |
29 | 31 | | |
30 | 32 | | |
| 33 | + | |
| 34 | + | |
31 | 35 | | |
32 | 36 | | |
33 | 37 | | |
| |||
0 commit comments