/mcuboot-3.7.0/sim/src/ |
D | depends.rs | 13 fn my_version(&self, offset: usize, slot: usize) -> ImageVersion; in my_version() 16 fn my_deps(&self, offset: usize, slot: usize) -> Vec<ImageVersion>; in my_deps() 40 fn my_version(&self, _offset: usize, slot: usize) -> ImageVersion { in my_version() 41 let slot = if self.test.downgrade { in my_version() localVariable 42 1 - slot in my_version() 44 slot in my_version() 46 ImageVersion::new_synthetic(self.number as u8, slot as u8, 0) in my_version() 138 fn my_version(&self, _offset: usize, slot: usize) -> ImageVersion { in my_version() 139 let slot = if self.test.downgrade { in my_version() localVariable 140 1 - slot in my_version() [all …]
|
D | image.rs | 1377 fn mark_bad_status_with_rate(&self, flash: &mut SimMultiFlash, slot: usize, in mark_bad_status_with_rate() 1385 let dev_id = &image.slots[slot].dev_id; in mark_bad_status_with_rate() 1388 let off = &image.slots[slot].base_off; in mark_bad_status_with_rate() 1389 let len = &image.slots[slot].len; in mark_bad_status_with_rate() 1397 fn reset_bad_status(&self, flash: &mut SimMultiFlash, slot: usize) { in reset_bad_status() 1403 let dev_id = &image.slots[slot].dev_id; in reset_bad_status() 1587 fn verify_images(&self, flash: &SimMultiFlash, slot: usize, against: usize) -> bool { in verify_images() 1589 verify_image(flash, &image.slots[slot], in verify_images() 1617 fn verify_trailers_loose(&self, flash: &SimMultiFlash, slot: usize, in verify_trailers_loose() 1621 verify_trailer(flash, &image.slots[slot], in verify_trailers_loose() [all …]
|
/mcuboot-3.7.0/boot/bootutil/src/ |
D | bootutil_priv.h | 179 #define BOOT_LOG_IMAGE_INFO(slot, hdr) \ argument 181 ((slot) == BOOT_PRIMARY_SLOT) ? "Primary" : "Secondary", \ 291 int boot_read_image_header(struct boot_loader_state *state, int slot, 301 int boot_write_enc_key(const struct flash_area *fap, uint8_t slot, 303 int boot_read_enc_key(const struct flash_area *fap, uint8_t slot, 367 #define BOOT_IMG(state, slot) ((state)->imgs[BOOT_CURR_IMG(state)][(slot)]) argument 368 #define BOOT_IMG_AREA(state, slot) (BOOT_IMG(state, slot).area) argument 379 boot_img_hdr(struct boot_loader_state *state, size_t slot) in boot_img_hdr() argument 381 return &BOOT_IMG(state, slot).hdr; in boot_img_hdr() 385 boot_img_num_sectors(const struct boot_loader_state *state, size_t slot) in boot_img_num_sectors() argument [all …]
|
D | bootutil_misc.c | 191 boot_enc_key_off(const struct flash_area *fap, uint8_t slot) in boot_enc_key_off() argument 194 return boot_swap_size_off(fap) - ((slot + 1) * BOOT_ENC_TLV_ALIGN_SIZE); in boot_enc_key_off() 196 return boot_swap_size_off(fap) - ((slot + 1) * BOOT_ENC_KEY_ALIGN_SIZE); in boot_enc_key_off() 267 boot_read_enc_key(const struct flash_area *fap, uint8_t slot, struct boot_status *bs) in boot_read_enc_key() argument 275 off = boot_enc_key_off(fap, slot); in boot_read_enc_key() 277 rc = flash_area_read(fap, off, bs->enctlv[slot], BOOT_ENC_TLV_ALIGN_SIZE); in boot_read_enc_key() 280 if (bs->enctlv[slot][i] != 0xff) { in boot_read_enc_key() 286 rc = boot_enc_decrypt(bs->enctlv[slot], bs->enckey[slot]); in boot_read_enc_key() 290 rc = flash_area_read(fap, off, bs->enckey[slot], BOOT_ENC_KEY_ALIGN_SIZE); in boot_read_enc_key() 311 boot_write_enc_key(const struct flash_area *fap, uint8_t slot, in boot_write_enc_key() argument [all …]
|
D | encrypted.c | 340 boot_enc_init(struct enc_key_data *enc_state, uint8_t slot) in boot_enc_init() argument 342 bootutil_aes_ctr_init(&enc_state[slot].aes_ctr); in boot_enc_init() 347 boot_enc_drop(struct enc_key_data *enc_state, uint8_t slot) in boot_enc_drop() argument 349 bootutil_aes_ctr_drop(&enc_state[slot].aes_ctr); in boot_enc_drop() 354 boot_enc_set_key(struct enc_key_data *enc_state, uint8_t slot, in boot_enc_set_key() argument 359 rc = bootutil_aes_ctr_set_key(&enc_state[slot].aes_ctr, bs->enckey[slot]); in boot_enc_set_key() 361 boot_enc_drop(enc_state, slot); in boot_enc_set_key() 362 enc_state[slot].valid = 0; in boot_enc_set_key() 366 enc_state[slot].valid = 1; in boot_enc_set_key() 622 uint8_t slot; in boot_enc_load() local [all …]
|
D | loader.c | 219 uint32_t slot; in close_all_flash_areas() local 230 for (slot = 0; slot < BOOT_NUM_SLOTS; slot++) { in close_all_flash_areas() 231 flash_area_close(BOOT_IMG_AREA(state, BOOT_NUM_SLOTS - 1 - slot)); in close_all_flash_areas() 296 boot_verify_slot_dependencies(struct boot_loader_state *state, uint32_t slot); 369 uint8_t slot; in boot_verify_dependencies() local 379 slot = BOOT_SECONDARY_SLOT; in boot_verify_dependencies() 381 slot = BOOT_PRIMARY_SLOT; in boot_verify_dependencies() 384 rc = boot_verify_slot_dependencies(state, slot); in boot_verify_dependencies() 456 boot_verify_slot_dependencies(struct boot_loader_state *state, uint32_t slot) in boot_verify_slot_dependencies() argument 466 area_id = flash_area_id_from_multi_image_slot(BOOT_CURR_IMG(state), slot); in boot_verify_slot_dependencies() [all …]
|
D | swap_misc.c | 38 uint8_t slot; in swap_erase_trailer_sectors() local 58 slot = BOOT_PRIMARY_SLOT; in swap_erase_trailer_sectors() 60 slot = BOOT_SECONDARY_SLOT; in swap_erase_trailer_sectors() 66 sector = boot_img_num_sectors(state, slot) - 1; in swap_erase_trailer_sectors() 70 sz = boot_img_sector_size(state, slot, sector); in swap_erase_trailer_sectors() 71 off = boot_img_sector_off(state, slot, sector); in swap_erase_trailer_sectors()
|
/mcuboot-3.7.0/sim/mcuboot-sys/csupport/ |
D | run.c | 297 int flash_area_id_from_multi_image_slot(int image_index, int slot) in flash_area_id_from_multi_image_slot() argument 299 switch (slot) { in flash_area_id_from_multi_image_slot() 373 struct area *slot; in flash_area_to_sectors() local 386 slot = &flash_areas->slots[i]; in flash_area_to_sectors() 388 if (slot->num_areas > (uint32_t)*cnt) { in flash_area_to_sectors() 393 *cnt = slot->num_areas; in flash_area_to_sectors() 394 memcpy(ret, slot->areas, slot->num_areas * sizeof(struct flash_area)); in flash_area_to_sectors() 403 struct area *slot; in flash_area_get_sectors() local 416 slot = &flash_areas->slots[i]; in flash_area_get_sectors() 418 if (slot->num_areas > *count) { in flash_area_get_sectors() [all …]
|
/mcuboot-3.7.0/boot/zephyr/ |
D | hooks_sample.c | 29 int boot_read_image_header_hook(int img_index, int slot, in boot_read_image_header_hook() argument 32 if (img_index == 1 && slot == 0) { in boot_read_image_header_hook() 45 fih_ret boot_image_check_hook(int img_index, int slot) in boot_image_check_hook() argument 47 if (img_index == 1 && slot == 0) { in boot_image_check_hook() 92 int boot_img_install_stat_hook(int image_index, int slot, int *img_install_stat) in boot_img_install_stat_hook() argument
|
D | flash_map_extended.c | 59 int flash_area_id_from_multi_image_slot(int image_index, int slot) in flash_area_id_from_multi_image_slot() argument 61 switch (slot) { in flash_area_id_from_multi_image_slot() 74 int flash_area_id_from_image_slot(int slot) in flash_area_id_from_image_slot() argument 76 return flash_area_id_from_multi_image_slot(0, slot); in flash_area_id_from_image_slot()
|
/mcuboot-3.7.0/boot/espressif/include/ |
D | esp_loader.h | 9 void start_cpu0_image(int image_index, int slot, unsigned int hdr_offset); 11 void start_cpu1_image(int image_index, int slot, unsigned int hdr_offset); 14 void esp_app_image_load(int image_index, int slot, unsigned int hdr_offset, unsigned int *entry_add…
|
/mcuboot-3.7.0/sim/mcuboot-sys/ |
D | Cargo.toml | 41 # Disable validation of the primary slot 42 validate-primary-slot = [] 44 # Encrypt image in the secondary slot using RSA-OAEP-2048 47 # Encrypt image in the secondary slot using AES-256-CTR and RSA-OAEP-2048 50 # Encrypt image in the secondary slot using AES-KW-128 53 # Encrypt image in the secondary slot using AES-256-CTR and AES-KW-256 56 # Encrypt image in the secondary slot using ECIES-P256 59 # Encrypt image in the secondary slot using AES-256-CTR and ECIES-P256 62 # Encrypt image in the secondary slot using ECIES-P256 using Mbed TLS 65 # Encrypt image in the secondary slot using ECIES-X25519 [all …]
|
/mcuboot-3.7.0/docs/ |
D | testplan-mynewt.md | 20 Build and load good image in slot 0: 35 Build and load image in slot 1 with no signing, signed with 43 * `newtmgr image test <hash of slot 1>` 54 Build and load good image in slot 0: 59 Build and load image in slot 1 with no signing, signed with 72 * `newtmgr image test <hash of slot 1>` 81 Build/load blinky to slot 0: 92 * `newtmgr image confirm <hash of slot 1>` 94 This should not swap and delete the image in slot 1 when signed with the wrong 95 key, otherwise the image in slot 1 should be *moved* to slot 0 and slot 1 should [all …]
|
D | readme-mbed.md | 14 * `"mcuboot.primary-slot-address"`: address of the primary slot in the internal flash 15 * `"mcuboot.slot-size"`: size of an image slot (only one image, two slots are currently supported) 16 …max-img-sectors"`: maximum number of sectors, should be at least the number of sectors in each slot 17 …ict_size"`: the maximum size of the bootloader, such that it does not overlap with the primary slot 19 More configurations such as signing algorithm, slot swapping, etc. can be found in [mbed_lib.json](… 21 ### Providing a secondary slot 23 You need to provide an instance of `mbed::BlockDevice` as the secondary slot. It can be any types o… 24 * Its size equals the `"mcuboot.slot-size"` you have set 27 In order for MCUboot to access your secondary slot, the interface to implement is 35 …already the default) and you have provided configurations and a secondary slot BlockDevice as expl… [all …]
|
/mcuboot-3.7.0/boot/espressif/port/ |
D | esp_loader.c | 38 void esp_app_image_load(int image_index, int slot, unsigned int hdr_offset, unsigned int *entry_add… in esp_app_image_load() argument 44 area_id = flash_area_id_from_multi_image_slot(image_index, slot); in esp_app_image_load() 50 BOOT_LOG_INF("Loading image %d - slot %d from flash, area id: %d", image_index, slot, area_id); in esp_app_image_load() 90 void start_cpu0_image(int image_index, int slot, unsigned int hdr_offset) in start_cpu0_image() argument 93 esp_app_image_load(image_index, slot, hdr_offset, &entry_addr); in start_cpu0_image() 99 void start_cpu1_image(int image_index, int slot, unsigned int hdr_offset) in start_cpu1_image() argument 102 esp_app_image_load(image_index, slot, hdr_offset, &entry_addr); in start_cpu1_image()
|
/mcuboot-3.7.0/boot/cypress/MCUBootApp/ |
D | ExternalMemory.md | 5 Given document describes the use of external memory module as a secondary (upgrade) slot with Cypre… 10 Using external memory for secondary slot allows to nearly double the size of Boot Image. 18 * There only one module is being used for secondary slot; 20 * The address for secondary slot should start from 0x18000000. 22 * The slot size for upgrade slot is even (or smaller) to erase size (0x40000) of given memory modul… 31 `[0x10018000, 0x10028000]` - primary slot for BlinkyApp; 33 `[0x18000000, 0x18010000]` - secondary slot for BlinkyApp; 41 `[0x10018000, 0x10028000]` - primary1 slot for BlinkyApp; 43 `[0x18000000, 0x18010000]` - secondary1 slot for BlinkyApp; 45 `[0x10038000, 0x10048000]` - primary2 slot for user app ; [all …]
|
/mcuboot-3.7.0/boot/espressif/ |
D | main.c | 56 …int slot = (rsp->br_image_off == CONFIG_ESP_IMAGE0_PRIMARY_START_ADDRESS) ? PRIMARY_SLOT : SECONDA… in do_boot() local 57 start_cpu0_image(IMAGE_INDEX_0, slot, rsp->br_hdr->ih_hdr_size); in do_boot() 61 int read_image_header(uint32_t img_index, uint32_t slot, struct image_header *img_header) in read_image_header() argument 67 area_id = flash_area_id_from_multi_image_slot(img_index, slot); in read_image_header() 87 void do_boot_appcpu(uint32_t img_index, uint32_t slot) in do_boot_appcpu() argument 91 if (read_image_header(img_index, slot, &img_header) != 0) { in do_boot_appcpu() 95 start_cpu1_image(img_index, slot, img_header.ih_hdr_size); in do_boot_appcpu()
|
/mcuboot-3.7.0/boot/bootutil/include/bootutil/ |
D | boot_hooks.h | 70 int boot_read_image_header_hook(int img_index, int slot, 85 fih_ret boot_image_check_hook(int img_index, int slot); 157 int boot_img_install_stat_hook(int image_index, int slot,
|
D | enc_key.h | 51 int boot_enc_init(struct enc_key_data *enc_state, uint8_t slot); 52 int boot_enc_drop(struct enc_key_data *enc_state, uint8_t slot); 53 int boot_enc_set_key(struct enc_key_data *enc_state, uint8_t slot,
|
/mcuboot-3.7.0/boot/zephyr/include/flash_map_backend/ |
D | flash_map_backend.h | 47 int flash_area_id_from_image_slot(int slot); 48 int flash_area_id_from_multi_image_slot(int image_index, int slot);
|
/mcuboot-3.7.0/boot/zephyr/include/sysflash/ |
D | sysflash.h | 41 static inline uint32_t __flash_area_ids_for_slot(int img, int slot) in __flash_area_ids_for_slot() argument 46 return all_slots[img * 2 + slot]; in __flash_area_ids_for_slot()
|
/mcuboot-3.7.0/boot/cypress/BlinkyApp/ |
D | Readme.md | 13 * Can be built for BOOT slot or UPGRADE slot of bootloader. 45 The following command will build regular HEX file of a BlinkyApp for BOOT slot. Substitute `PLATFOR… 74 * first image BOOT (PRIMARY) slot start `0x10018000` 75 * slot size `0x10000` 76 * second image BOOT (PRIMARY) slot start `0x10038000` 78 To get appropriate artifact for second image PRIMARY slot run this command: 92 …om original boot image address. This one in line above suggests secondary slot will start from `0x… 138 …output hex file, 0x%VALUE% - offset for output hex file. Value 0x10000 is slot size MCUboot Bootlo… 139 …- `BOOT` (default) - build image for BOOT slot of MCUboot Bootloader, `UPGRADE` - build image for … 142 **NOTE**: In case of `UPGRADE` image `HEADER_OFFSET` should be set to MCUboot Bootloader slot size. [all …]
|
/mcuboot-3.7.0/boot/mynewt/flash_map_backend/src/ |
D | flash_map_extended.c | 25 int flash_area_id_from_multi_image_slot(int image_index, int slot) in flash_area_id_from_multi_image_slot() argument 27 switch (slot) { in flash_area_id_from_multi_image_slot()
|
/mcuboot-3.7.0/sim/mcuboot-sys/csupport/storage/ |
D | flash_map.h | 163 int flash_area_id_from_image_slot(int slot); 164 int flash_area_id_from_multi_image_slot(int image_index, int slot);
|
/mcuboot-3.7.0/boot/mbed/include/flash_map_backend/ |
D | flash_map_backend.h | 160 int flash_area_id_from_image_slot(int slot); 161 int flash_area_id_from_multi_image_slot(int image_index, int slot);
|