File tree Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Original file line number Diff line number Diff line change 12
12
/**
13
13
* Finds the preferred slot containing the image based on bootloader requests.
14
14
*/
15
- int boot_find_next_slot_hook (struct boot_loader_state * state , uint8_t image , uint32_t * active_slot )
15
+ int boot_find_next_slot_hook (struct boot_loader_state * state , uint8_t image ,
16
+ enum boot_slot * active_slot )
16
17
{
17
18
#ifdef CONFIG_NRF_MCUBOOT_BOOT_REQUEST
18
- uint32_t slot = BOOT_REQUEST_NO_PREFERRED_SLOT ;
19
+ enum boot_slot slot = BOOT_SLOT_NONE ;
19
20
20
21
if (active_slot == NULL ) {
21
22
return BOOT_HOOK_REGULAR ;
22
23
}
23
24
24
25
slot = boot_request_get_preferred_slot (image );
25
- if (slot != BOOT_REQUEST_NO_PREFERRED_SLOT ) {
26
+ if (slot != BOOT_SLOT_NONE ) {
26
27
if (state -> slot_usage [image ].slot_available [slot ]) {
27
28
* active_slot = slot ;
28
29
return 0 ;
Original file line number Diff line number Diff line change @@ -162,14 +162,14 @@ static void toggle_slot_for_single_boot(void)
162
162
{
163
163
int err = 0 ;
164
164
enum ab_boot_slot active_slot = active_boot_slot_get ();
165
- enum ab_boot_slot new_slot = SLOT_INVALID ;
165
+ enum boot_slot new_slot = BOOT_SLOT_NONE ;
166
166
167
167
if (active_slot == SLOT_A ) {
168
168
LOG_INF ("Temporarily switching slots (A -> B)" );
169
- new_slot = SLOT_B ;
169
+ new_slot = BOOT_SLOT_SECONDARY ;
170
170
} else if (active_slot == SLOT_B ) {
171
171
LOG_INF ("Temporarily switching slots (B -> A)" );
172
- new_slot = SLOT_A ;
172
+ new_slot = BOOT_SLOT_PRIMARY ;
173
173
} else {
174
174
LOG_ERR ("Cannot determine active slot, cannot toggle" );
175
175
return ;
Original file line number Diff line number Diff line change @@ -128,7 +128,7 @@ manifest:
128
128
compare-by-default : true
129
129
- name : mcuboot
130
130
repo-path : sdk-mcuboot
131
- revision : 511e742327020ebe42df2e4b45a3ca8d0f3e6611
131
+ revision : 85349537b3bc4e8e9e7542abd0303adf28177dcb
132
132
path : bootloader/mcuboot
133
133
- name : qcbor
134
134
url : https://github.com/laurencelundblade/QCBOR
You can’t perform that action at this time.
0 commit comments