|
45 | 45 | * the default upgrade mode.
|
46 | 46 | */
|
47 | 47 |
|
48 |
| -/* Uncomment to enable the overwrite-only code path. */ |
49 |
| -/* #define MCUBOOT_OVERWRITE_ONLY */ |
| 48 | +/* Define to enable the swap-using-move code path. */ |
| 49 | +#if defined(CONFIG_ESP_BOOT_SWAP_USING_MOVE) |
| 50 | +#define MCUBOOT_SWAP_USING_MOVE 1 |
| 51 | +#endif |
50 | 52 |
|
51 |
| -#ifdef MCUBOOT_OVERWRITE_ONLY |
| 53 | +/* Define to enable the overwrite-only code path. */ |
| 54 | +#if defined(CONFIG_ESP_BOOT_UPGRADE_ONLY) |
| 55 | +#define MCUBOOT_OVERWRITE_ONLY |
52 | 56 | /* Uncomment to only erase and overwrite those primary slot sectors needed
|
53 | 57 | * to install the new image, rather than the entire image slot. */
|
54 | 58 | /* #define MCUBOOT_OVERWRITE_ONLY_FAST */
|
55 | 59 | #endif
|
56 | 60 |
|
57 |
| -/* Uncomment to enable the direct-xip code path. */ |
58 |
| -/* #define MCUBOOT_DIRECT_XIP */ |
| 61 | +/* Define to enable the direct-xip code path (CURRENTLY UNSUPPORTED!). */ |
| 62 | +#if defined(CONFIG_ESP_BOOT_DIRECT_XIP) |
| 63 | +#define MCUBOOT_DIRECT_XIP |
| 64 | +#endif |
59 | 65 |
|
60 |
| -/* Define to enable the ram-load code path. */ |
61 |
| -#if defined(CONFIG_BOOT_RAM_LOAD) |
| 66 | +/* Define to enable the ram-load code path (CURRENTLY UNSUPPORTED!). */ |
| 67 | +#if defined(CONFIG_ESP_BOOT_RAM_LOAD) |
62 | 68 | #define MCUBOOT_RAM_LOAD
|
63 | 69 | #endif
|
64 | 70 |
|
| 71 | +/* If none of the above paths is defined, define CONFIG_ESP_BOOT_SWAP_USING_SCRATCH. |
| 72 | + * |
| 73 | + * Note: MCUBOOT_SWAP_USING_SCRATCH does not have to be defined, as it will be defined |
| 74 | + * by MCUboot in bootutil_priv.h. |
| 75 | + */ |
| 76 | +#if !defined(CONFIG_ESP_BOOT_SWAP_USING_SCRATCH) && \ |
| 77 | + !defined(CONFIG_ESP_BOOT_SWAP_USING_MOVE) && \ |
| 78 | + !defined(CONFIG_ESP_BOOT_UPGRADE_ONLY) && \ |
| 79 | + !defined(CONFIG_ESP_BOOT_DIRECT_XIP) && \ |
| 80 | + !defined(CONFIG_ESP_BOOT_RAM_LOAD) |
| 81 | +#define CONFIG_ESP_BOOT_SWAP_USING_SCRATCH |
| 82 | +#endif |
| 83 | + |
| 84 | + |
65 | 85 | /*
|
66 | 86 | * Cryptographic settings
|
67 | 87 | *
|
|
0 commit comments