Skip to content

Commit 0989c67

Browse files
PK Chanioannisg
authored andcommitted
subsys: spm: added FICR ranges in read request service.
About the FICR ranges: The range 0x204 ~ 0xC20 has been published in infocenter. The range 0x130 ~ 0x134 happens in system_nrf9160 for checking whether certain errata fixes need to be applied. Signed-off-by: PK Chan <[email protected]>
1 parent a975449 commit 0989c67

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

subsys/spm/secure_services.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
*
44
* SPDX-License-Identifier: LicenseRef-BSD-5-Clause-Nordic
55
*/
6+
#include <zephyr.h>
67
#include <errno.h>
78
#include <cortex_m/tz.h>
89
#include <misc/reboot.h>
@@ -50,6 +51,13 @@ int spm_secure_services_init(void)
5051
}
5152

5253
#ifdef CONFIG_SPM_SERVICE_READ
54+
55+
#define FICR_BASE NRF_FICR_S_BASE
56+
#define FICR_PUBLIC_ADDR (FICR_BASE + 0x204)
57+
#define FICR_PUBLIC_SIZE 0xA1C
58+
#define FICR_RESTRICTED_ADDR (FICR_BASE + 0x130)
59+
#define FICR_RESTRICTED_SIZE 0x8
60+
5361
struct read_range {
5462
u32_t start;
5563
size_t size;
@@ -64,6 +72,10 @@ int spm_request_read(void *destination, u32_t addr, size_t len)
6472
{.start = PM_MCUBOOT_PAD_ADDRESS,
6573
.size = PM_MCUBOOT_PAD_SIZE},
6674
#endif
75+
{.start = FICR_PUBLIC_ADDR,
76+
.size = FICR_PUBLIC_SIZE},
77+
{.start = FICR_RESTRICTED_ADDR,
78+
.size = FICR_RESTRICTED_SIZE},
6779
};
6880

6981
if (destination == NULL || len <= 0) {

0 commit comments

Comments
 (0)