Commit a7f9f77
committed
[nrf noup] sysflash: Correct ALL_AVAILABLE_SLOTS when MCUBOOT is not image 2
Consider an nRF5340 application with the following sysbuild config:
```
SB_CONFIG_BOOTLOADER_MCUBOOT=y
SB_CONFIG_BOOT_SIGNATURE_TYPE_ECDSA_P256=y
SB_CONFIG_PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY=y
SB_CONFIG_SECURE_BOOT_APPCORE=y
SB_CONFIG_SECURE_BOOT_NETCORE=y
SB_CONFIG_NETCORE_APP_UPDATE=y
SB_CONFIG_MCUBOOT_NRF53_MULTI_IMAGE_UPDATE=y
SB_CONFIG_MCUBOOT_MODE_OVERWRITE_ONLY=y
```
In this case, we have a total of 3 updatable images (app, net, mcuboot).
`MCUBOOT_IMAGE_NUMBER = 2` (i.e. `CONFIG_UPDATEABLE_IMAGE_NUMBER = 2`),
as the app secondary partition is reused for MCUBoot secondary.
`CONFIG_MCUBOOT_MCUBOOT_IMAGE_NUMBER = 2` as the net core image has
index 1.
In this case, we should fall through to the definition of
`ALL_AVAILABLE_SLOTS` that caters for 2 updatable images.1 parent d79a412 commit a7f9f77
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
| 34 | + | |
35 | 35 | | |
36 | | - | |
| 36 | + | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| |||
0 commit comments