Skip to content

Commit 94833c5

Browse files
committed
Platform: Nordic: Do not refer SPM_ASSERT in nrfx_glue.h for DOMAIN_NS==1
Fixes a build issue for USART driver when building the NS side Signed-off-by: Antonio de Angelis <[email protected]> Change-Id: Ieab76ce9b3961f2f06ae8abd719c8eacfd067528
1 parent 39c7e46 commit 94833c5

File tree

1 file changed

+9
-0
lines changed
  • platform/ext/target/nordic_nrf/common/core/common

1 file changed

+9
-0
lines changed

platform/ext/target/nordic_nrf/common/core/common/nrfx_glue.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,12 @@
3232
#ifndef NRFX_GLUE_H__
3333
#define NRFX_GLUE_H__
3434

35+
/* Include the spm utilities for the SPM_ASSERT symbol */
36+
#if defined(DOMAIN_NS) && (DOMAIN_NS == 1)
37+
#include <assert.h>
38+
#else
3539
#include <utilities.h>
40+
#endif
3641

3742
#include <soc/nrfx_coredep.h>
3843

@@ -59,8 +64,12 @@ extern "C" {
5964
#if defined(NDEBUG)
6065
#define NRFX_ASSERT(expression) if (0 && (expression)) {}
6166
#else
67+
#if defined(DOMAIN_NS) && (DOMAIN_NS == 1)
68+
#define NRFX_ASSERT(expression) assert(expression)
69+
#else
6270
#define NRFX_ASSERT(expression) SPM_ASSERT(expression)
6371
#endif
72+
#endif
6473

6574
/**
6675
* @brief Macro for placing a compile time assertion.

0 commit comments

Comments
 (0)