Skip to content

Commit

Permalink
[nrf noup] bootutil: Fix missing PCD define check
Browse files Browse the repository at this point in the history
Fixes a missing PCD define check, an image might have the
network core partition layout set but if PCD support is not
enabled then it should not assume that PCD support is part
of mcuboot.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
  • Loading branch information
nordicjm committed Sep 1, 2023
1 parent 02ae1c8 commit 71ec266
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions boot/bootutil/src/loader.c
Original file line number Diff line number Diff line change
Expand Up @@ -1016,7 +1016,7 @@ boot_validated_swap_type(struct boot_loader_state *state,
}

#if defined(CONFIG_SOC_NRF5340_CPUAPP) && defined(PM_CPUNET_B0N_ADDRESS) \
&& !defined(CONFIG_NRF53_MULTI_IMAGE_UPDATE)
&& !defined(CONFIG_NRF53_MULTI_IMAGE_UPDATE) && defined(CONFIG_PCD_APP)
/* If the update is valid, and it targets the network core: perform the
* update and indicate to the caller of this function that no update is
* available
Expand Down Expand Up @@ -1072,7 +1072,8 @@ boot_validated_swap_type(struct boot_loader_state *state,
swap_type = BOOT_SWAP_TYPE_NONE;
}
}
#endif /* CONFIG_SOC_NRF5340_CPUAPP */
#endif /* CONFIG_SOC_NRF5340_CPUAPP && PM_CPUNET_B0N_ADDRESS &&
!CONFIG_NRF53_MULTI_IMAGE_UPDATE && CONFIG_PCD_APP */
}

return swap_type;
Expand Down

0 comments on commit 71ec266

Please sign in to comment.