Skip to content

Commit 2b40c6a

Browse files
committed
nrf_security: Allow setting the kmu reserved area with dts
The kmu_push_area was only allowed to be set with dts for the ram images. Now more images will use it and hence the dependency on RAM images is removed. Also create a Kconfig which depends on the dts entry so that it can be used in the build system. Signed-off-by: Georgios Vasilakis <[email protected]>
1 parent 48579bc commit 2b40c6a

File tree

1 file changed

+1
-10
lines changed
  • subsys/nrf_security/src/drivers/cracen/cracenpsa/src

1 file changed

+1
-10
lines changed

subsys/nrf_security/src/drivers/cracen/cracenpsa/src/kmu.c

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,16 +33,7 @@ extern nrf_security_mutex_t cracen_mutex_symmetric;
3333

3434
#define KMU_PUSH_AREA_SIZE 64
3535

36-
/* When execution in place (CONFIG_XIP) is not enabled, which in practice means that when Zephyr is
37-
* built for a RAM loaded image, the Zephyr linker script always places the RAM loaded image in the
38-
* top address of the RAM and then loads the linker scripts defined with the Zephyr SECTION_PROLOGUE
39-
* macros. Using SECTION_PROLOGUE macros to set the address of the kmu_push_area is
40-
* incompatible with RAM loaded images. The Zephyr reserved-memory devicetree methodology works for
41-
* both use cases but it requires heavy updates of multiple devicetree files and overlays. In order
42-
* to support the RAM loaded images use cases faster initial support for reserving the memory of
43-
* nrf_kmu_reserved_push_area though devicetree is limited to RAM loaded images.
44-
*/
45-
#if DT_NODE_EXISTS(DT_NODELABEL(nrf_kmu_reserved_push_area)) && !CONFIG_XIP
36+
#if DT_NODE_EXISTS(DT_NODELABEL(nrf_kmu_reserved_push_area))
4637

4738
#include <zephyr/dt-bindings/memory-attr/memory-attr.h>
4839
#include <zephyr/linker/devicetree_regions.h>

0 commit comments

Comments
 (0)