Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2019, Arm Limited. All rights reserved. |
| 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | * |
| 6 | */ |
| 7 | |
| 8 | /*********** WARNING: This is an auto-generated file. Do not edit! ***********/ |
| 9 | |
| 10 | #ifndef __TFM_SPM_DB_INC__ |
| 11 | #define __TFM_SPM_DB_INC__ |
| 12 | |
| 13 | #include "spm_api.h" |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 14 | #include "psa_manifest/sid.h" |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 15 | |
| 16 | /**************************************************************************/ |
| 17 | /** IRQ count per partition */ |
| 18 | /**************************************************************************/ |
| 19 | #define TFM_PARTITION_TFM_SP_STORAGE_IRQ_COUNT 0 |
| 20 | |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 21 | #define TFM_PARTITION_TFM_SP_ITS_IRQ_COUNT 0 |
| 22 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 23 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 24 | #define TFM_PARTITION_TFM_SP_AUDIT_LOG_IRQ_COUNT 0 |
| 25 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 26 | |
| 27 | #define TFM_PARTITION_TFM_SP_CRYPTO_IRQ_COUNT 0 |
| 28 | |
| 29 | #ifdef TFM_PARTITION_PLATFORM |
| 30 | #define TFM_PARTITION_TFM_SP_PLATFORM_IRQ_COUNT 0 |
| 31 | #endif /* TFM_PARTITION_PLATFORM */ |
| 32 | |
| 33 | #define TFM_PARTITION_TFM_SP_INITIAL_ATTESTATION_IRQ_COUNT 0 |
| 34 | |
| 35 | #ifdef TFM_PARTITION_TEST_CORE |
| 36 | #define TFM_PARTITION_TFM_SP_CORE_TEST_IRQ_COUNT 0 |
| 37 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 38 | |
| 39 | #ifdef TFM_PARTITION_TEST_CORE |
| 40 | #define TFM_PARTITION_TFM_SP_CORE_TEST_2_IRQ_COUNT 0 |
| 41 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 42 | |
| 43 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 44 | #define TFM_PARTITION_TFM_SP_SECURE_TEST_PARTITION_IRQ_COUNT 0 |
| 45 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 46 | |
| 47 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 48 | #define TFM_PARTITION_TFM_SP_IPC_SERVICE_TEST_IRQ_COUNT 0 |
| 49 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 50 | |
| 51 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 52 | #define TFM_PARTITION_TFM_SP_IPC_CLIENT_TEST_IRQ_COUNT 0 |
| 53 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 54 | |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 55 | #ifdef TFM_ENABLE_IRQ_TEST |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 56 | #define TFM_PARTITION_TFM_IRQ_TEST_1_IRQ_COUNT 1 |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 57 | #endif /* TFM_ENABLE_IRQ_TEST */ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 58 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 59 | #ifdef TFM_PARTITION_TEST_SST |
| 60 | #define TFM_PARTITION_TFM_SP_SST_TEST_IRQ_COUNT 0 |
| 61 | #endif /* TFM_PARTITION_TEST_SST */ |
| 62 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 63 | /**************************************************************************/ |
| 64 | /** Declarations of partition init functions */ |
| 65 | /**************************************************************************/ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 66 | #ifdef TFM_PSA_API |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 67 | extern void tfm_nspm_thread_entry(void); |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 68 | #endif |
| 69 | |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 70 | extern void tfm_sst_req_mngr_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 71 | |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 72 | extern void tfm_its_req_mngr_init(void); |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 73 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 74 | #ifdef TFM_PARTITION_AUDIT_LOG |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 75 | extern void audit_core_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 76 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 77 | |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 78 | extern void tfm_crypto_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 79 | |
| 80 | #ifdef TFM_PARTITION_PLATFORM |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 81 | extern void platform_sp_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 82 | #endif /* TFM_PARTITION_PLATFORM */ |
| 83 | |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 84 | extern void attest_partition_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 85 | |
| 86 | #ifdef TFM_PARTITION_TEST_CORE |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 87 | extern void core_test_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 88 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 89 | |
| 90 | #ifdef TFM_PARTITION_TEST_CORE |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 91 | extern void core_test_2_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 92 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 93 | |
| 94 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 95 | extern void tfm_secure_client_service_init(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 96 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 97 | |
| 98 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 99 | extern void ipc_service_test_main(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 100 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 101 | |
| 102 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 103 | extern void ipc_client_test_main(void); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 104 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 105 | |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 106 | #ifdef TFM_ENABLE_IRQ_TEST |
Edison Ai | 9c48d20 | 2019-10-12 16:57:21 +0800 | [diff] [blame] | 107 | extern void tfm_irq_test_1_init(void); |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 108 | #endif /* TFM_ENABLE_IRQ_TEST */ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 109 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 110 | #ifdef TFM_PARTITION_TEST_SST |
| 111 | extern void tfm_sst_test_init(void); |
| 112 | #endif /* TFM_PARTITION_TEST_SST */ |
| 113 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 114 | /**************************************************************************/ |
| 115 | /** Memory region declarations */ |
| 116 | /**************************************************************************/ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 117 | #ifdef TFM_PSA_API |
| 118 | REGION_DECLARE(Image$$, ARM_LIB_STACK, $$ZI$$Base); |
| 119 | REGION_DECLARE(Image$$, ARM_LIB_STACK, $$ZI$$Limit); |
| 120 | |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 121 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, $$Base); |
| 122 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, $$Limit); |
| 123 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, $$RO$$Base); |
| 124 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, $$RO$$Limit); |
| 125 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, _DATA$$RW$$Base); |
| 126 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, _DATA$$RW$$Limit); |
| 127 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, _DATA$$ZI$$Base); |
| 128 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, _DATA$$ZI$$Limit); |
| 129 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, _STACK$$ZI$$Base); |
| 130 | REGION_DECLARE(Image$$, TFM_SP_STORAGE_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 131 | |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 132 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, $$Base); |
| 133 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, $$Limit); |
| 134 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, $$RO$$Base); |
| 135 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, $$RO$$Limit); |
| 136 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, _DATA$$RW$$Base); |
| 137 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, _DATA$$RW$$Limit); |
| 138 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, _DATA$$ZI$$Base); |
| 139 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, _DATA$$ZI$$Limit); |
| 140 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, _STACK$$ZI$$Base); |
| 141 | REGION_DECLARE(Image$$, TFM_SP_ITS_LINKER, _STACK$$ZI$$Limit); |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 142 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 143 | #ifdef TFM_PARTITION_AUDIT_LOG |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 144 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, $$Base); |
| 145 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, $$Limit); |
| 146 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, $$RO$$Base); |
| 147 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, $$RO$$Limit); |
| 148 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, _DATA$$RW$$Base); |
| 149 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, _DATA$$RW$$Limit); |
| 150 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, _DATA$$ZI$$Base); |
| 151 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, _DATA$$ZI$$Limit); |
| 152 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, _STACK$$ZI$$Base); |
| 153 | REGION_DECLARE(Image$$, TFM_SP_AUDIT_LOG_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 154 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 155 | |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 156 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, $$Base); |
| 157 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, $$Limit); |
| 158 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, $$RO$$Base); |
| 159 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, $$RO$$Limit); |
| 160 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, _DATA$$RW$$Base); |
| 161 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, _DATA$$RW$$Limit); |
| 162 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, _DATA$$ZI$$Base); |
| 163 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, _DATA$$ZI$$Limit); |
| 164 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, _STACK$$ZI$$Base); |
| 165 | REGION_DECLARE(Image$$, TFM_SP_CRYPTO_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 166 | |
| 167 | #ifdef TFM_PARTITION_PLATFORM |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 168 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, $$Base); |
| 169 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, $$Limit); |
| 170 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, $$RO$$Base); |
| 171 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, $$RO$$Limit); |
| 172 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, _DATA$$RW$$Base); |
| 173 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, _DATA$$RW$$Limit); |
| 174 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, _DATA$$ZI$$Base); |
| 175 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, _DATA$$ZI$$Limit); |
| 176 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, _STACK$$ZI$$Base); |
| 177 | REGION_DECLARE(Image$$, TFM_SP_PLATFORM_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 178 | #endif /* TFM_PARTITION_PLATFORM */ |
| 179 | |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 180 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, $$Base); |
| 181 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, $$Limit); |
| 182 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, $$RO$$Base); |
| 183 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, $$RO$$Limit); |
| 184 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$RW$$Base); |
| 185 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$RW$$Limit); |
| 186 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$ZI$$Base); |
| 187 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$ZI$$Limit); |
| 188 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, _STACK$$ZI$$Base); |
| 189 | REGION_DECLARE(Image$$, TFM_SP_INITIAL_ATTESTATION_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 190 | |
| 191 | #ifdef TFM_PARTITION_TEST_CORE |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 192 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, $$Base); |
| 193 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, $$Limit); |
| 194 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, $$RO$$Base); |
| 195 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, $$RO$$Limit); |
| 196 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, _DATA$$RW$$Base); |
| 197 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, _DATA$$RW$$Limit); |
| 198 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, _DATA$$ZI$$Base); |
| 199 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, _DATA$$ZI$$Limit); |
| 200 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, _STACK$$ZI$$Base); |
| 201 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 202 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 203 | |
| 204 | #ifdef TFM_PARTITION_TEST_CORE |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 205 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, $$Base); |
| 206 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, $$Limit); |
| 207 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, $$RO$$Base); |
| 208 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, $$RO$$Limit); |
| 209 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, _DATA$$RW$$Base); |
| 210 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, _DATA$$RW$$Limit); |
| 211 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, _DATA$$ZI$$Base); |
| 212 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, _DATA$$ZI$$Limit); |
| 213 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, _STACK$$ZI$$Base); |
| 214 | REGION_DECLARE(Image$$, TFM_SP_CORE_TEST_2_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 215 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 216 | |
| 217 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 218 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, $$Base); |
| 219 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, $$Limit); |
| 220 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, $$RO$$Base); |
| 221 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, $$RO$$Limit); |
| 222 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$RW$$Base); |
| 223 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$RW$$Limit); |
| 224 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$ZI$$Base); |
| 225 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$ZI$$Limit); |
| 226 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, _STACK$$ZI$$Base); |
| 227 | REGION_DECLARE(Image$$, TFM_SP_SECURE_TEST_PARTITION_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 228 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 229 | |
| 230 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 231 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, $$Base); |
| 232 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, $$Limit); |
| 233 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, $$RO$$Base); |
| 234 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, $$RO$$Limit); |
| 235 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$RW$$Base); |
| 236 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$RW$$Limit); |
| 237 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$ZI$$Base); |
| 238 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$ZI$$Limit); |
| 239 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, _STACK$$ZI$$Base); |
| 240 | REGION_DECLARE(Image$$, TFM_SP_IPC_SERVICE_TEST_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 241 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 242 | |
| 243 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 244 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, $$Base); |
| 245 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, $$Limit); |
| 246 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, $$RO$$Base); |
| 247 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, $$RO$$Limit); |
| 248 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$RW$$Base); |
| 249 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$RW$$Limit); |
| 250 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$ZI$$Base); |
| 251 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$ZI$$Limit); |
| 252 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, _STACK$$ZI$$Base); |
| 253 | REGION_DECLARE(Image$$, TFM_SP_IPC_CLIENT_TEST_LINKER, _STACK$$ZI$$Limit); |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 254 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 255 | |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 256 | #ifdef TFM_ENABLE_IRQ_TEST |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 257 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, $$Base); |
| 258 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, $$Limit); |
| 259 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, $$RO$$Base); |
| 260 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, $$RO$$Limit); |
| 261 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, _DATA$$RW$$Base); |
| 262 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, _DATA$$RW$$Limit); |
| 263 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, _DATA$$ZI$$Base); |
| 264 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, _DATA$$ZI$$Limit); |
| 265 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, _STACK$$ZI$$Base); |
| 266 | REGION_DECLARE(Image$$, TFM_IRQ_TEST_1_LINKER, _STACK$$ZI$$Limit); |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 267 | #endif /* TFM_ENABLE_IRQ_TEST */ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 268 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 269 | #ifdef TFM_PARTITION_TEST_SST |
| 270 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, $$Base); |
| 271 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, $$Limit); |
| 272 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, $$RO$$Base); |
| 273 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, $$RO$$Limit); |
| 274 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, _DATA$$RW$$Base); |
| 275 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, _DATA$$RW$$Limit); |
| 276 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, _DATA$$ZI$$Base); |
| 277 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, _DATA$$ZI$$Limit); |
| 278 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, _STACK$$ZI$$Base); |
| 279 | REGION_DECLARE(Image$$, TFM_SP_SST_TEST_LINKER, _STACK$$ZI$$Limit); |
| 280 | #endif /* TFM_PARTITION_TEST_SST */ |
| 281 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 282 | #endif /* defined(TFM_PSA_API) */ |
| 283 | |
Edison Ai | 66fbdf1 | 2019-07-08 16:05:07 +0800 | [diff] [blame] | 284 | #ifndef TFM_PSA_API |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 285 | /**************************************************************************/ |
| 286 | /** Context stacks for IRQ handling */ |
| 287 | /**************************************************************************/ |
| 288 | /* The max size of the context stack can be calculated as a function of the IRQ |
| 289 | * count of the secure partition: |
| 290 | * |
| 291 | * max_stack_size = intr_ctx_size + (IRQ_CNT * (intr_ctx_size + hndl_ctx_size)) |
| 292 | * |
| 293 | * where: |
| 294 | * intr_ctx: Frame pushed when the partition is interrupted |
| 295 | * hndl_ctx: Frame pushed when the partition is handling an interrupt |
| 296 | */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 297 | static uint32_t ns_interrupt_ctx_stack[ |
| 298 | sizeof(struct interrupted_ctx_stack_frame_t) / sizeof(uint32_t)]; |
| 299 | |
| 300 | static uint32_t tfm_core_interrupt_ctx_stack[ |
| 301 | sizeof(struct interrupted_ctx_stack_frame_t) / sizeof(uint32_t)]; |
| 302 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 303 | static uint32_t ctx_stack_TFM_SP_STORAGE[ |
| 304 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 305 | (TFM_PARTITION_TFM_SP_STORAGE_IRQ_COUNT) * ( |
| 306 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 307 | sizeof(struct handler_ctx_stack_frame_t) |
| 308 | )) / sizeof(uint32_t)]; |
| 309 | |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 310 | static uint32_t ctx_stack_TFM_SP_ITS[ |
| 311 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 312 | (TFM_PARTITION_TFM_SP_ITS_IRQ_COUNT) * ( |
| 313 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 314 | sizeof(struct handler_ctx_stack_frame_t) |
| 315 | )) / sizeof(uint32_t)]; |
| 316 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 317 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 318 | static uint32_t ctx_stack_TFM_SP_AUDIT_LOG[ |
| 319 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 320 | (TFM_PARTITION_TFM_SP_AUDIT_LOG_IRQ_COUNT) * ( |
| 321 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 322 | sizeof(struct handler_ctx_stack_frame_t) |
| 323 | )) / sizeof(uint32_t)]; |
| 324 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 325 | |
| 326 | static uint32_t ctx_stack_TFM_SP_CRYPTO[ |
| 327 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 328 | (TFM_PARTITION_TFM_SP_CRYPTO_IRQ_COUNT) * ( |
| 329 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 330 | sizeof(struct handler_ctx_stack_frame_t) |
| 331 | )) / sizeof(uint32_t)]; |
| 332 | |
| 333 | #ifdef TFM_PARTITION_PLATFORM |
| 334 | static uint32_t ctx_stack_TFM_SP_PLATFORM[ |
| 335 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 336 | (TFM_PARTITION_TFM_SP_PLATFORM_IRQ_COUNT) * ( |
| 337 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 338 | sizeof(struct handler_ctx_stack_frame_t) |
| 339 | )) / sizeof(uint32_t)]; |
| 340 | #endif /* TFM_PARTITION_PLATFORM */ |
| 341 | |
| 342 | static uint32_t ctx_stack_TFM_SP_INITIAL_ATTESTATION[ |
| 343 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 344 | (TFM_PARTITION_TFM_SP_INITIAL_ATTESTATION_IRQ_COUNT) * ( |
| 345 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 346 | sizeof(struct handler_ctx_stack_frame_t) |
| 347 | )) / sizeof(uint32_t)]; |
| 348 | |
| 349 | #ifdef TFM_PARTITION_TEST_CORE |
| 350 | static uint32_t ctx_stack_TFM_SP_CORE_TEST[ |
| 351 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 352 | (TFM_PARTITION_TFM_SP_CORE_TEST_IRQ_COUNT) * ( |
| 353 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 354 | sizeof(struct handler_ctx_stack_frame_t) |
| 355 | )) / sizeof(uint32_t)]; |
| 356 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 357 | |
| 358 | #ifdef TFM_PARTITION_TEST_CORE |
| 359 | static uint32_t ctx_stack_TFM_SP_CORE_TEST_2[ |
| 360 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 361 | (TFM_PARTITION_TFM_SP_CORE_TEST_2_IRQ_COUNT) * ( |
| 362 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 363 | sizeof(struct handler_ctx_stack_frame_t) |
| 364 | )) / sizeof(uint32_t)]; |
| 365 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 366 | |
| 367 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 368 | static uint32_t ctx_stack_TFM_SP_SECURE_TEST_PARTITION[ |
| 369 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 370 | (TFM_PARTITION_TFM_SP_SECURE_TEST_PARTITION_IRQ_COUNT) * ( |
| 371 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 372 | sizeof(struct handler_ctx_stack_frame_t) |
| 373 | )) / sizeof(uint32_t)]; |
| 374 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 375 | |
| 376 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 377 | static uint32_t ctx_stack_TFM_SP_IPC_SERVICE_TEST[ |
| 378 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 379 | (TFM_PARTITION_TFM_SP_IPC_SERVICE_TEST_IRQ_COUNT) * ( |
| 380 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 381 | sizeof(struct handler_ctx_stack_frame_t) |
| 382 | )) / sizeof(uint32_t)]; |
| 383 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 384 | |
| 385 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 386 | static uint32_t ctx_stack_TFM_SP_IPC_CLIENT_TEST[ |
| 387 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 388 | (TFM_PARTITION_TFM_SP_IPC_CLIENT_TEST_IRQ_COUNT) * ( |
| 389 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 390 | sizeof(struct handler_ctx_stack_frame_t) |
| 391 | )) / sizeof(uint32_t)]; |
| 392 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 393 | |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 394 | #ifdef TFM_ENABLE_IRQ_TEST |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 395 | static uint32_t ctx_stack_TFM_IRQ_TEST_1[ |
| 396 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 397 | (TFM_PARTITION_TFM_IRQ_TEST_1_IRQ_COUNT) * ( |
| 398 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 399 | sizeof(struct handler_ctx_stack_frame_t) |
| 400 | )) / sizeof(uint32_t)]; |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 401 | #endif /* TFM_ENABLE_IRQ_TEST */ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 402 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 403 | #ifdef TFM_PARTITION_TEST_SST |
| 404 | static uint32_t ctx_stack_TFM_SP_SST_TEST[ |
| 405 | (sizeof(struct interrupted_ctx_stack_frame_t) + |
| 406 | (TFM_PARTITION_TFM_SP_SST_TEST_IRQ_COUNT) * ( |
| 407 | sizeof(struct interrupted_ctx_stack_frame_t) + |
| 408 | sizeof(struct handler_ctx_stack_frame_t) |
| 409 | )) / sizeof(uint32_t)]; |
| 410 | #endif /* TFM_PARTITION_TEST_SST */ |
| 411 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 412 | |
| 413 | uint32_t *ctx_stack_list[] = |
| 414 | { |
| 415 | ns_interrupt_ctx_stack, |
| 416 | tfm_core_interrupt_ctx_stack, |
| 417 | ctx_stack_TFM_SP_STORAGE, |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 418 | ctx_stack_TFM_SP_ITS, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 419 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 420 | ctx_stack_TFM_SP_AUDIT_LOG, |
| 421 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 422 | ctx_stack_TFM_SP_CRYPTO, |
| 423 | #ifdef TFM_PARTITION_PLATFORM |
| 424 | ctx_stack_TFM_SP_PLATFORM, |
| 425 | #endif /* TFM_PARTITION_PLATFORM */ |
| 426 | ctx_stack_TFM_SP_INITIAL_ATTESTATION, |
| 427 | #ifdef TFM_PARTITION_TEST_CORE |
| 428 | ctx_stack_TFM_SP_CORE_TEST, |
| 429 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 430 | #ifdef TFM_PARTITION_TEST_CORE |
| 431 | ctx_stack_TFM_SP_CORE_TEST_2, |
| 432 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 433 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 434 | ctx_stack_TFM_SP_SECURE_TEST_PARTITION, |
| 435 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 436 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 437 | ctx_stack_TFM_SP_IPC_SERVICE_TEST, |
| 438 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 439 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 440 | ctx_stack_TFM_SP_IPC_CLIENT_TEST, |
| 441 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 442 | #ifdef TFM_ENABLE_IRQ_TEST |
| 443 | ctx_stack_TFM_IRQ_TEST_1, |
| 444 | #endif /* TFM_ENABLE_IRQ_TEST */ |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 445 | #ifdef TFM_PARTITION_TEST_SST |
| 446 | ctx_stack_TFM_SP_SST_TEST, |
| 447 | #endif /* TFM_PARTITION_TEST_SST */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 448 | }; |
Edison Ai | 66fbdf1 | 2019-07-08 16:05:07 +0800 | [diff] [blame] | 449 | #endif /* !defined(TFM_PSA_API) */ |
| 450 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 451 | /**************************************************************************/ |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 452 | /** Dependencies array for Secure Partition */ |
| 453 | /**************************************************************************/ |
| 454 | static int32_t dependencies_TFM_SP_STORAGE[] = |
| 455 | { |
| 456 | TFM_CRYPTO_SID, |
| 457 | }; |
| 458 | |
| 459 | static int32_t dependencies_TFM_SP_INITIAL_ATTESTATION[] = |
| 460 | { |
| 461 | TFM_CRYPTO_SID, |
| 462 | }; |
| 463 | |
| 464 | #ifdef TFM_PARTITION_TEST_CORE |
| 465 | static int32_t dependencies_TFM_SP_CORE_TEST[] = |
| 466 | { |
| 467 | SPM_CORE_TEST_2_INVERT_SID, |
| 468 | SPM_CORE_TEST_2_GET_EVERY_SECOND_BYTE_SID, |
| 469 | SPM_CORE_TEST_2_SLAVE_SERVICE_SID, |
| 470 | }; |
| 471 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 472 | |
| 473 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 474 | static int32_t dependencies_TFM_SP_SECURE_TEST_PARTITION[] = |
| 475 | { |
| 476 | TFM_CRYPTO_SID, |
| 477 | TFM_SST_SET_SID, |
| 478 | TFM_SST_GET_SID, |
| 479 | TFM_SST_GET_INFO_SID, |
| 480 | TFM_SST_REMOVE_SID, |
| 481 | TFM_SST_GET_SUPPORT_SID, |
| 482 | TFM_ITS_SET_SID, |
| 483 | TFM_ITS_GET_SID, |
| 484 | TFM_ITS_GET_INFO_SID, |
| 485 | TFM_ITS_REMOVE_SID, |
| 486 | TFM_ATTEST_GET_TOKEN_SID, |
| 487 | TFM_ATTEST_GET_TOKEN_SIZE_SID, |
| 488 | TFM_ATTEST_GET_PUBLIC_KEY_SID, |
| 489 | TFM_SST_TEST_PREPARE_SID, |
| 490 | }; |
| 491 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 492 | |
| 493 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 494 | static int32_t dependencies_TFM_SP_IPC_CLIENT_TEST[] = |
| 495 | { |
| 496 | IPC_SERVICE_TEST_PSA_ACCESS_APP_READ_ONLY_MEM_SID, |
| 497 | IPC_SERVICE_TEST_PSA_ACCESS_APP_MEM_SID, |
| 498 | IPC_SERVICE_TEST_BASIC_SID, |
| 499 | IPC_SERVICE_TEST_APP_ACCESS_PSA_MEM_SID, |
| 500 | }; |
| 501 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 502 | |
| 503 | #ifdef TFM_PARTITION_TEST_SST |
| 504 | static int32_t dependencies_TFM_SP_SST_TEST[] = |
| 505 | { |
| 506 | TFM_CRYPTO_SID, |
| 507 | }; |
| 508 | #endif /* TFM_PARTITION_TEST_SST */ |
| 509 | |
| 510 | /**************************************************************************/ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 511 | /** The static data of the partition list */ |
| 512 | /**************************************************************************/ |
| 513 | const struct spm_partition_static_data_t static_data_list[] = |
| 514 | { |
| 515 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 516 | #ifdef TFM_PSA_API |
| 517 | .psa_framework_version = 0x0100, |
| 518 | #endif /* defined(TFM_PSA_API) */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 519 | .partition_id = TFM_SP_NON_SECURE_ID, |
| 520 | #ifdef TFM_PSA_API |
David Hu | 90128b7 | 2019-09-23 16:35:41 +0800 | [diff] [blame] | 521 | #if TFM_MULTI_CORE_TOPOLOGY |
| 522 | .partition_flags = SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_IPC, |
| 523 | #else |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 524 | .partition_flags = SPM_PART_FLAG_APP_ROT | SPM_PART_FLAG_IPC, |
David Hu | 90128b7 | 2019-09-23 16:35:41 +0800 | [diff] [blame] | 525 | #endif |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 526 | .partition_priority = TFM_PRIORITY_LOW, |
| 527 | .partition_init = tfm_nspm_thread_entry, |
| 528 | #else |
| 529 | .partition_flags = 0, |
| 530 | #endif |
| 531 | }, |
| 532 | |
| 533 | #ifndef TFM_PSA_API |
| 534 | { |
| 535 | .partition_id = TFM_SP_CORE_ID, |
| 536 | .partition_flags = SPM_PART_FLAG_APP_ROT | SPM_PART_FLAG_PSA_ROT, |
| 537 | }, |
| 538 | #endif |
| 539 | |
| 540 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 541 | #ifdef TFM_PSA_API |
| 542 | .psa_framework_version = 0x0100, |
| 543 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 544 | .partition_id = TFM_SP_STORAGE, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 545 | .partition_flags = SPM_PART_FLAG_IPC |
| 546 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 547 | , |
| 548 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 549 | .partition_init = tfm_sst_req_mngr_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 550 | .dependencies_num = 1, |
| 551 | .p_dependencies = dependencies_TFM_SP_STORAGE, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 552 | }, |
| 553 | |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 554 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 555 | #ifdef TFM_PSA_API |
| 556 | .psa_framework_version = 0x0100, |
| 557 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 558 | .partition_id = TFM_SP_ITS, |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 559 | .partition_flags = SPM_PART_FLAG_IPC |
| 560 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 561 | , |
| 562 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 563 | .partition_init = tfm_its_req_mngr_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 564 | .dependencies_num = 0, |
| 565 | .p_dependencies = NULL, |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 566 | }, |
| 567 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 568 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 569 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 570 | #ifdef TFM_PSA_API |
| 571 | .psa_framework_version = 0x0100, |
| 572 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 573 | .partition_id = TFM_SP_AUDIT_LOG, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 574 | .partition_flags = 0 |
| 575 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 576 | , |
| 577 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 578 | .partition_init = audit_core_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 579 | .dependencies_num = 0, |
| 580 | .p_dependencies = NULL, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 581 | }, |
| 582 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 583 | |
| 584 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 585 | #ifdef TFM_PSA_API |
| 586 | .psa_framework_version = 0x0100, |
| 587 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 588 | .partition_id = TFM_SP_CRYPTO, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 589 | .partition_flags = SPM_PART_FLAG_IPC |
| 590 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 591 | , |
| 592 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 593 | .partition_init = tfm_crypto_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 594 | .dependencies_num = 0, |
| 595 | .p_dependencies = NULL, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 596 | }, |
| 597 | |
| 598 | #ifdef TFM_PARTITION_PLATFORM |
| 599 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 600 | #ifdef TFM_PSA_API |
| 601 | .psa_framework_version = 0x0100, |
| 602 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 603 | .partition_id = TFM_SP_PLATFORM, |
Mate Toth-Pal | 179a156 | 2019-11-08 11:40:27 +0100 | [diff] [blame] | 604 | .partition_flags = SPM_PART_FLAG_IPC |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 605 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 606 | , |
| 607 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 608 | .partition_init = platform_sp_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 609 | .dependencies_num = 0, |
| 610 | .p_dependencies = NULL, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 611 | }, |
| 612 | #endif /* TFM_PARTITION_PLATFORM */ |
| 613 | |
| 614 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 615 | #ifdef TFM_PSA_API |
| 616 | .psa_framework_version = 0x0100, |
| 617 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 618 | .partition_id = TFM_SP_INITIAL_ATTESTATION, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 619 | .partition_flags = SPM_PART_FLAG_IPC |
| 620 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 621 | , |
| 622 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 623 | .partition_init = attest_partition_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 624 | .dependencies_num = 1, |
| 625 | .p_dependencies = dependencies_TFM_SP_INITIAL_ATTESTATION, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 626 | }, |
| 627 | |
| 628 | #ifdef TFM_PARTITION_TEST_CORE |
| 629 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 630 | #ifdef TFM_PSA_API |
| 631 | .psa_framework_version = 0x0100, |
| 632 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 633 | .partition_id = TFM_SP_CORE_TEST, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 634 | .partition_flags = SPM_PART_FLAG_IPC |
Mate Toth-Pal | acae8bd | 2019-09-10 16:47:11 +0200 | [diff] [blame] | 635 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 636 | , |
| 637 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 638 | .partition_init = core_test_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 639 | .dependencies_num = 3, |
| 640 | .p_dependencies = dependencies_TFM_SP_CORE_TEST, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 641 | }, |
| 642 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 643 | |
| 644 | #ifdef TFM_PARTITION_TEST_CORE |
| 645 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 646 | #ifdef TFM_PSA_API |
| 647 | .psa_framework_version = 0x0100, |
| 648 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 649 | .partition_id = TFM_SP_CORE_TEST_2, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 650 | .partition_flags = SPM_PART_FLAG_IPC |
| 651 | | SPM_PART_FLAG_APP_ROT |
| 652 | , |
| 653 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 654 | .partition_init = core_test_2_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 655 | .dependencies_num = 0, |
| 656 | .p_dependencies = NULL, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 657 | }, |
| 658 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 659 | |
| 660 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 661 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 662 | #ifdef TFM_PSA_API |
| 663 | .psa_framework_version = 0x0100, |
| 664 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 665 | .partition_id = TFM_SP_SECURE_TEST_PARTITION, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 666 | .partition_flags = SPM_PART_FLAG_IPC |
| 667 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 668 | , |
| 669 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 670 | .partition_init = tfm_secure_client_service_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 671 | .dependencies_num = 14, |
| 672 | .p_dependencies = dependencies_TFM_SP_SECURE_TEST_PARTITION, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 673 | }, |
| 674 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 675 | |
| 676 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 677 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 678 | #ifdef TFM_PSA_API |
| 679 | .psa_framework_version = 0x0100, |
| 680 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 681 | .partition_id = TFM_SP_IPC_SERVICE_TEST, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 682 | .partition_flags = SPM_PART_FLAG_IPC |
| 683 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 684 | , |
| 685 | .partition_priority = TFM_PRIORITY(HIGH), |
| 686 | .partition_init = ipc_service_test_main, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 687 | .dependencies_num = 0, |
| 688 | .p_dependencies = NULL, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 689 | }, |
| 690 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 691 | |
| 692 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 693 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 694 | #ifdef TFM_PSA_API |
| 695 | .psa_framework_version = 0x0100, |
| 696 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 697 | .partition_id = TFM_SP_IPC_CLIENT_TEST, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 698 | .partition_flags = SPM_PART_FLAG_IPC |
| 699 | | SPM_PART_FLAG_APP_ROT |
| 700 | , |
| 701 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 702 | .partition_init = ipc_client_test_main, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 703 | .dependencies_num = 4, |
| 704 | .p_dependencies = dependencies_TFM_SP_IPC_CLIENT_TEST, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 705 | }, |
| 706 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 707 | |
| 708 | #ifdef TFM_ENABLE_IRQ_TEST |
| 709 | { |
Edison Ai | f050170 | 2019-10-11 14:36:42 +0800 | [diff] [blame] | 710 | #ifdef TFM_PSA_API |
| 711 | .psa_framework_version = 0x0100, |
| 712 | #endif /* defined(TFM_PSA_API) */ |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 713 | .partition_id = TFM_IRQ_TEST_1, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 714 | .partition_flags = SPM_PART_FLAG_IPC |
| 715 | | SPM_PART_FLAG_APP_ROT |
| 716 | , |
| 717 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 718 | .partition_init = tfm_irq_test_1_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 719 | .dependencies_num = 0, |
| 720 | .p_dependencies = NULL, |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 721 | }, |
| 722 | #endif /* TFM_ENABLE_IRQ_TEST */ |
| 723 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 724 | #ifdef TFM_PARTITION_TEST_SST |
| 725 | { |
| 726 | #ifdef TFM_PSA_API |
| 727 | .psa_framework_version = 0x0100, |
| 728 | #endif /* defined(TFM_PSA_API) */ |
| 729 | .partition_id = TFM_SP_SST_TEST, |
| 730 | .partition_flags = SPM_PART_FLAG_IPC |
| 731 | | SPM_PART_FLAG_PSA_ROT | SPM_PART_FLAG_APP_ROT |
| 732 | , |
| 733 | .partition_priority = TFM_PRIORITY(NORMAL), |
| 734 | .partition_init = tfm_sst_test_init, |
Edison Ai | e728fbf | 2019-11-13 09:37:12 +0800 | [diff] [blame^] | 735 | .dependencies_num = 1, |
| 736 | .p_dependencies = dependencies_TFM_SP_SST_TEST, |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 737 | }, |
| 738 | #endif /* TFM_PARTITION_TEST_SST */ |
| 739 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 740 | }; |
| 741 | |
| 742 | /**************************************************************************/ |
| 743 | /** The platform data of the partition list */ |
| 744 | /**************************************************************************/ |
| 745 | const struct tfm_spm_partition_platform_data_t *platform_data_list[] = |
| 746 | { |
| 747 | NULL, |
| 748 | |
| 749 | #ifndef TFM_PSA_API |
| 750 | NULL, |
| 751 | #endif |
| 752 | |
| 753 | NULL, |
| 754 | |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 755 | NULL, |
| 756 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 757 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 758 | /* FIXME: Only adding the first mmio region */ |
| 759 | #ifdef AUDIT_UART_REDIRECTION |
| 760 | TFM_PERIPHERAL_UART1, |
| 761 | #else /* AUDIT_UART_REDIRECTION */ |
| 762 | NULL, |
| 763 | #endif /* AUDIT_UART_REDIRECTION */ |
| 764 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 765 | |
| 766 | NULL, |
| 767 | |
| 768 | #ifdef TFM_PARTITION_PLATFORM |
| 769 | NULL, |
| 770 | #endif /* TFM_PARTITION_PLATFORM */ |
| 771 | |
| 772 | NULL, |
| 773 | |
| 774 | #ifdef TFM_PARTITION_TEST_CORE |
| 775 | /* FIXME: Only adding the first mmio region */ |
| 776 | TFM_PERIPHERAL_FPGA_IO, |
| 777 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 778 | |
| 779 | #ifdef TFM_PARTITION_TEST_CORE |
| 780 | NULL, |
| 781 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 782 | |
| 783 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 784 | /* FIXME: Only adding the first mmio region */ |
| 785 | TFM_PERIPHERAL_STD_UART, |
| 786 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 787 | |
| 788 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 789 | NULL, |
| 790 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 791 | |
| 792 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 793 | NULL, |
| 794 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 795 | |
| 796 | #ifdef TFM_ENABLE_IRQ_TEST |
| 797 | /* FIXME: Only adding the first mmio region */ |
| 798 | TFM_PERIPHERAL_TIMER0, |
| 799 | #endif /* TFM_ENABLE_IRQ_TEST */ |
| 800 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 801 | #ifdef TFM_PARTITION_TEST_SST |
| 802 | NULL, |
| 803 | #endif /* TFM_PARTITION_TEST_SST */ |
| 804 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 805 | }; |
| 806 | |
| 807 | /**************************************************************************/ |
| 808 | /** The memory data of the partition list */ |
| 809 | /**************************************************************************/ |
| 810 | #ifdef TFM_PSA_API |
| 811 | const struct tfm_spm_partition_memory_data_t memory_data_list[] = |
| 812 | { |
| 813 | { |
| 814 | .stack_bottom = PART_REGION_ADDR(ARM_LIB_STACK, $$ZI$$Base), |
| 815 | .stack_top = PART_REGION_ADDR(ARM_LIB_STACK, $$ZI$$Limit), |
| 816 | .rw_start = PART_REGION_ADDR(ARM_LIB_STACK, $$ZI$$Base), |
| 817 | }, |
| 818 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 819 | .code_start = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, $$Base), |
| 820 | .code_limit = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, $$Limit), |
| 821 | .ro_start = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, $$RO$$Base), |
| 822 | .ro_limit = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, $$RO$$Limit), |
| 823 | .rw_start = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, _DATA$$RW$$Base), |
| 824 | .rw_limit = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, _DATA$$RW$$Limit), |
| 825 | .zi_start = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, _DATA$$ZI$$Base), |
| 826 | .zi_limit = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, _DATA$$ZI$$Limit), |
| 827 | .stack_bottom = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, _STACK$$ZI$$Base), |
| 828 | .stack_top = PART_REGION_ADDR(TFM_SP_STORAGE_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 829 | }, |
| 830 | |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 831 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 832 | .code_start = PART_REGION_ADDR(TFM_SP_ITS_LINKER, $$Base), |
| 833 | .code_limit = PART_REGION_ADDR(TFM_SP_ITS_LINKER, $$Limit), |
| 834 | .ro_start = PART_REGION_ADDR(TFM_SP_ITS_LINKER, $$RO$$Base), |
| 835 | .ro_limit = PART_REGION_ADDR(TFM_SP_ITS_LINKER, $$RO$$Limit), |
| 836 | .rw_start = PART_REGION_ADDR(TFM_SP_ITS_LINKER, _DATA$$RW$$Base), |
| 837 | .rw_limit = PART_REGION_ADDR(TFM_SP_ITS_LINKER, _DATA$$RW$$Limit), |
| 838 | .zi_start = PART_REGION_ADDR(TFM_SP_ITS_LINKER, _DATA$$ZI$$Base), |
| 839 | .zi_limit = PART_REGION_ADDR(TFM_SP_ITS_LINKER, _DATA$$ZI$$Limit), |
| 840 | .stack_bottom = PART_REGION_ADDR(TFM_SP_ITS_LINKER, _STACK$$ZI$$Base), |
| 841 | .stack_top = PART_REGION_ADDR(TFM_SP_ITS_LINKER, _STACK$$ZI$$Limit), |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 842 | }, |
| 843 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 844 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 845 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 846 | .code_start = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, $$Base), |
| 847 | .code_limit = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, $$Limit), |
| 848 | .ro_start = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, $$RO$$Base), |
| 849 | .ro_limit = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, $$RO$$Limit), |
| 850 | .rw_start = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, _DATA$$RW$$Base), |
| 851 | .rw_limit = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, _DATA$$RW$$Limit), |
| 852 | .zi_start = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, _DATA$$ZI$$Base), |
| 853 | .zi_limit = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, _DATA$$ZI$$Limit), |
| 854 | .stack_bottom = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, _STACK$$ZI$$Base), |
| 855 | .stack_top = PART_REGION_ADDR(TFM_SP_AUDIT_LOG_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 856 | }, |
| 857 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 858 | |
| 859 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 860 | .code_start = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, $$Base), |
| 861 | .code_limit = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, $$Limit), |
| 862 | .ro_start = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, $$RO$$Base), |
| 863 | .ro_limit = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, $$RO$$Limit), |
| 864 | .rw_start = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, _DATA$$RW$$Base), |
| 865 | .rw_limit = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, _DATA$$RW$$Limit), |
| 866 | .zi_start = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, _DATA$$ZI$$Base), |
| 867 | .zi_limit = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, _DATA$$ZI$$Limit), |
| 868 | .stack_bottom = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, _STACK$$ZI$$Base), |
| 869 | .stack_top = PART_REGION_ADDR(TFM_SP_CRYPTO_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 870 | }, |
| 871 | |
| 872 | #ifdef TFM_PARTITION_PLATFORM |
| 873 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 874 | .code_start = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, $$Base), |
| 875 | .code_limit = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, $$Limit), |
| 876 | .ro_start = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, $$RO$$Base), |
| 877 | .ro_limit = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, $$RO$$Limit), |
| 878 | .rw_start = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, _DATA$$RW$$Base), |
| 879 | .rw_limit = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, _DATA$$RW$$Limit), |
| 880 | .zi_start = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, _DATA$$ZI$$Base), |
| 881 | .zi_limit = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, _DATA$$ZI$$Limit), |
| 882 | .stack_bottom = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, _STACK$$ZI$$Base), |
| 883 | .stack_top = PART_REGION_ADDR(TFM_SP_PLATFORM_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 884 | }, |
| 885 | #endif /* TFM_PARTITION_PLATFORM */ |
| 886 | |
| 887 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 888 | .code_start = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, $$Base), |
| 889 | .code_limit = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, $$Limit), |
| 890 | .ro_start = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, $$RO$$Base), |
| 891 | .ro_limit = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, $$RO$$Limit), |
| 892 | .rw_start = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$RW$$Base), |
| 893 | .rw_limit = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$RW$$Limit), |
| 894 | .zi_start = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$ZI$$Base), |
| 895 | .zi_limit = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, _DATA$$ZI$$Limit), |
| 896 | .stack_bottom = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, _STACK$$ZI$$Base), |
| 897 | .stack_top = PART_REGION_ADDR(TFM_SP_INITIAL_ATTESTATION_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 898 | }, |
| 899 | |
| 900 | #ifdef TFM_PARTITION_TEST_CORE |
| 901 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 902 | .code_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, $$Base), |
| 903 | .code_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, $$Limit), |
| 904 | .ro_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, $$RO$$Base), |
| 905 | .ro_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, $$RO$$Limit), |
| 906 | .rw_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, _DATA$$RW$$Base), |
| 907 | .rw_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, _DATA$$RW$$Limit), |
| 908 | .zi_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, _DATA$$ZI$$Base), |
| 909 | .zi_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, _DATA$$ZI$$Limit), |
| 910 | .stack_bottom = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, _STACK$$ZI$$Base), |
| 911 | .stack_top = PART_REGION_ADDR(TFM_SP_CORE_TEST_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 912 | }, |
| 913 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 914 | |
| 915 | #ifdef TFM_PARTITION_TEST_CORE |
| 916 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 917 | .code_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, $$Base), |
| 918 | .code_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, $$Limit), |
| 919 | .ro_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, $$RO$$Base), |
| 920 | .ro_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, $$RO$$Limit), |
| 921 | .rw_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, _DATA$$RW$$Base), |
| 922 | .rw_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, _DATA$$RW$$Limit), |
| 923 | .zi_start = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, _DATA$$ZI$$Base), |
| 924 | .zi_limit = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, _DATA$$ZI$$Limit), |
| 925 | .stack_bottom = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, _STACK$$ZI$$Base), |
| 926 | .stack_top = PART_REGION_ADDR(TFM_SP_CORE_TEST_2_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 927 | }, |
| 928 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 929 | |
| 930 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 931 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 932 | .code_start = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, $$Base), |
| 933 | .code_limit = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, $$Limit), |
| 934 | .ro_start = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, $$RO$$Base), |
| 935 | .ro_limit = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, $$RO$$Limit), |
| 936 | .rw_start = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$RW$$Base), |
| 937 | .rw_limit = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$RW$$Limit), |
| 938 | .zi_start = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$ZI$$Base), |
| 939 | .zi_limit = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, _DATA$$ZI$$Limit), |
| 940 | .stack_bottom = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, _STACK$$ZI$$Base), |
| 941 | .stack_top = PART_REGION_ADDR(TFM_SP_SECURE_TEST_PARTITION_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 942 | }, |
| 943 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 944 | |
| 945 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 946 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 947 | .code_start = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, $$Base), |
| 948 | .code_limit = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, $$Limit), |
| 949 | .ro_start = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, $$RO$$Base), |
| 950 | .ro_limit = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, $$RO$$Limit), |
| 951 | .rw_start = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$RW$$Base), |
| 952 | .rw_limit = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$RW$$Limit), |
| 953 | .zi_start = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$ZI$$Base), |
| 954 | .zi_limit = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, _DATA$$ZI$$Limit), |
| 955 | .stack_bottom = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, _STACK$$ZI$$Base), |
| 956 | .stack_top = PART_REGION_ADDR(TFM_SP_IPC_SERVICE_TEST_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 957 | }, |
| 958 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 959 | |
| 960 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 961 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 962 | .code_start = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, $$Base), |
| 963 | .code_limit = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, $$Limit), |
| 964 | .ro_start = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, $$RO$$Base), |
| 965 | .ro_limit = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, $$RO$$Limit), |
| 966 | .rw_start = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$RW$$Base), |
| 967 | .rw_limit = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$RW$$Limit), |
| 968 | .zi_start = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$ZI$$Base), |
| 969 | .zi_limit = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, _DATA$$ZI$$Limit), |
| 970 | .stack_bottom = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, _STACK$$ZI$$Base), |
| 971 | .stack_top = PART_REGION_ADDR(TFM_SP_IPC_CLIENT_TEST_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 972 | }, |
| 973 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 974 | |
| 975 | #ifdef TFM_ENABLE_IRQ_TEST |
| 976 | { |
Edison Ai | b2134e6 | 2019-10-11 18:24:47 +0800 | [diff] [blame] | 977 | .code_start = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, $$Base), |
| 978 | .code_limit = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, $$Limit), |
| 979 | .ro_start = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, $$RO$$Base), |
| 980 | .ro_limit = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, $$RO$$Limit), |
| 981 | .rw_start = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, _DATA$$RW$$Base), |
| 982 | .rw_limit = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, _DATA$$RW$$Limit), |
| 983 | .zi_start = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, _DATA$$ZI$$Base), |
| 984 | .zi_limit = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, _DATA$$ZI$$Limit), |
| 985 | .stack_bottom = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, _STACK$$ZI$$Base), |
| 986 | .stack_top = PART_REGION_ADDR(TFM_IRQ_TEST_1_LINKER, _STACK$$ZI$$Limit), |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 987 | }, |
| 988 | #endif /* TFM_ENABLE_IRQ_TEST */ |
| 989 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 990 | #ifdef TFM_PARTITION_TEST_SST |
| 991 | { |
| 992 | .code_start = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, $$Base), |
| 993 | .code_limit = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, $$Limit), |
| 994 | .ro_start = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, $$RO$$Base), |
| 995 | .ro_limit = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, $$RO$$Limit), |
| 996 | .rw_start = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, _DATA$$RW$$Base), |
| 997 | .rw_limit = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, _DATA$$RW$$Limit), |
| 998 | .zi_start = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, _DATA$$ZI$$Base), |
| 999 | .zi_limit = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, _DATA$$ZI$$Limit), |
| 1000 | .stack_bottom = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, _STACK$$ZI$$Base), |
| 1001 | .stack_top = PART_REGION_ADDR(TFM_SP_SST_TEST_LINKER, _STACK$$ZI$$Limit), |
| 1002 | }, |
| 1003 | #endif /* TFM_PARTITION_TEST_SST */ |
| 1004 | |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1005 | }; |
| 1006 | #endif /* defined(TFM_PSA_API) */ |
| 1007 | |
| 1008 | /**************************************************************************/ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1009 | /** The partition list for the DB */ |
| 1010 | /**************************************************************************/ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1011 | static struct spm_partition_desc_t partition_list [] = |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1012 | { |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1013 | {{}}, /* placeholder for Non-secure internal partition */ |
Mingyang Sun | da01a97 | 2019-07-12 17:32:59 +0800 | [diff] [blame] | 1014 | #ifndef TFM_PSA_API |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1015 | {{}}, /* placeholder for TF-M Core internal partition */ |
Mingyang Sun | da01a97 | 2019-07-12 17:32:59 +0800 | [diff] [blame] | 1016 | #endif /* !ifndefined(TFM_PSA_API) */ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1017 | |
| 1018 | /* -----------------------------------------------------------------------*/ |
| 1019 | /* - Partition DB record for TFM_SP_STORAGE */ |
| 1020 | /* -----------------------------------------------------------------------*/ |
| 1021 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1022 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1023 | .runtime_data = {}, |
| 1024 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1025 | .platform_data = NULL, |
| 1026 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1027 | }, |
| 1028 | |
| 1029 | /* -----------------------------------------------------------------------*/ |
TudorCretu | fb182bc | 2019-07-05 17:34:12 +0100 | [diff] [blame] | 1030 | /* - Partition DB record for TFM_SP_ITS */ |
| 1031 | /* -----------------------------------------------------------------------*/ |
| 1032 | { |
| 1033 | /* Runtime data */ |
| 1034 | .runtime_data = {}, |
| 1035 | .static_data = NULL, |
| 1036 | .platform_data = NULL, |
| 1037 | |
| 1038 | }, |
| 1039 | |
| 1040 | /* -----------------------------------------------------------------------*/ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1041 | /* - Partition DB record for TFM_SP_AUDIT_LOG */ |
| 1042 | /* -----------------------------------------------------------------------*/ |
| 1043 | #ifdef TFM_PARTITION_AUDIT_LOG |
| 1044 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1045 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1046 | .runtime_data = {}, |
| 1047 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1048 | .platform_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1049 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1050 | }, |
| 1051 | #endif /* TFM_PARTITION_AUDIT_LOG */ |
| 1052 | |
| 1053 | /* -----------------------------------------------------------------------*/ |
| 1054 | /* - Partition DB record for TFM_SP_CRYPTO */ |
| 1055 | /* -----------------------------------------------------------------------*/ |
| 1056 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1057 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1058 | .runtime_data = {}, |
| 1059 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1060 | .platform_data = NULL, |
| 1061 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1062 | }, |
| 1063 | |
| 1064 | /* -----------------------------------------------------------------------*/ |
| 1065 | /* - Partition DB record for TFM_SP_PLATFORM */ |
| 1066 | /* -----------------------------------------------------------------------*/ |
| 1067 | #ifdef TFM_PARTITION_PLATFORM |
| 1068 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1069 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1070 | .runtime_data = {}, |
| 1071 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1072 | .platform_data = NULL, |
| 1073 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1074 | }, |
| 1075 | #endif /* TFM_PARTITION_PLATFORM */ |
| 1076 | |
| 1077 | /* -----------------------------------------------------------------------*/ |
| 1078 | /* - Partition DB record for TFM_SP_INITIAL_ATTESTATION */ |
| 1079 | /* -----------------------------------------------------------------------*/ |
| 1080 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1081 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1082 | .runtime_data = {}, |
| 1083 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1084 | .platform_data = NULL, |
| 1085 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1086 | }, |
| 1087 | |
| 1088 | /* -----------------------------------------------------------------------*/ |
| 1089 | /* - Partition DB record for TFM_SP_CORE_TEST */ |
| 1090 | /* -----------------------------------------------------------------------*/ |
| 1091 | #ifdef TFM_PARTITION_TEST_CORE |
| 1092 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1093 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1094 | .runtime_data = {}, |
| 1095 | .static_data = NULL, |
| 1096 | .platform_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1097 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1098 | }, |
| 1099 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 1100 | |
| 1101 | /* -----------------------------------------------------------------------*/ |
| 1102 | /* - Partition DB record for TFM_SP_CORE_TEST_2 */ |
| 1103 | /* -----------------------------------------------------------------------*/ |
| 1104 | #ifdef TFM_PARTITION_TEST_CORE |
| 1105 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1106 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1107 | .runtime_data = {}, |
| 1108 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1109 | .platform_data = NULL, |
| 1110 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1111 | }, |
| 1112 | #endif /* TFM_PARTITION_TEST_CORE */ |
| 1113 | |
| 1114 | /* -----------------------------------------------------------------------*/ |
| 1115 | /* - Partition DB record for TFM_SP_SECURE_TEST_PARTITION */ |
| 1116 | /* -----------------------------------------------------------------------*/ |
| 1117 | #ifdef TFM_PARTITION_TEST_SECURE_SERVICES |
| 1118 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1119 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1120 | .runtime_data = {}, |
| 1121 | .static_data = NULL, |
| 1122 | .platform_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1123 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1124 | }, |
| 1125 | #endif /* TFM_PARTITION_TEST_SECURE_SERVICES */ |
| 1126 | |
| 1127 | /* -----------------------------------------------------------------------*/ |
| 1128 | /* - Partition DB record for TFM_SP_IPC_SERVICE_TEST */ |
| 1129 | /* -----------------------------------------------------------------------*/ |
| 1130 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 1131 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1132 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1133 | .runtime_data = {}, |
| 1134 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1135 | .platform_data = NULL, |
| 1136 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1137 | }, |
| 1138 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 1139 | |
| 1140 | /* -----------------------------------------------------------------------*/ |
| 1141 | /* - Partition DB record for TFM_SP_IPC_CLIENT_TEST */ |
| 1142 | /* -----------------------------------------------------------------------*/ |
| 1143 | #ifdef TFM_PARTITION_TEST_CORE_IPC |
| 1144 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1145 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1146 | .runtime_data = {}, |
| 1147 | .static_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1148 | .platform_data = NULL, |
| 1149 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1150 | }, |
| 1151 | #endif /* TFM_PARTITION_TEST_CORE_IPC */ |
| 1152 | |
| 1153 | /* -----------------------------------------------------------------------*/ |
| 1154 | /* - Partition DB record for TFM_IRQ_TEST_1 */ |
| 1155 | /* -----------------------------------------------------------------------*/ |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 1156 | #ifdef TFM_ENABLE_IRQ_TEST |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1157 | { |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1158 | /* Runtime data */ |
Summer Qin | 423dbef | 2019-08-22 15:59:35 +0800 | [diff] [blame] | 1159 | .runtime_data = {}, |
| 1160 | .static_data = NULL, |
| 1161 | .platform_data = NULL, |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1162 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1163 | }, |
David Hu | 33f2fd2 | 2019-08-16 15:32:39 +0800 | [diff] [blame] | 1164 | #endif /* TFM_ENABLE_IRQ_TEST */ |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1165 | |
Jamie Fox | 0e823a0 | 2019-10-28 17:28:19 +0000 | [diff] [blame] | 1166 | /* -----------------------------------------------------------------------*/ |
| 1167 | /* - Partition DB record for TFM_SP_SST_TEST */ |
| 1168 | /* -----------------------------------------------------------------------*/ |
| 1169 | #ifdef TFM_PARTITION_TEST_SST |
| 1170 | { |
| 1171 | /* Runtime data */ |
| 1172 | .runtime_data = {}, |
| 1173 | .static_data = NULL, |
| 1174 | .platform_data = NULL, |
| 1175 | |
| 1176 | }, |
| 1177 | #endif /* TFM_PARTITION_TEST_SST */ |
| 1178 | |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1179 | }; |
| 1180 | |
| 1181 | struct spm_partition_db_t g_spm_partition_db = { |
| 1182 | .is_init = 0, |
| 1183 | .partition_count = sizeof(partition_list) / sizeof(partition_list[0]), |
Edison Ai | 66fbdf1 | 2019-07-08 16:05:07 +0800 | [diff] [blame] | 1184 | #ifndef TFM_PSA_API |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1185 | .running_partition_idx = 0, |
Edison Ai | 66fbdf1 | 2019-07-08 16:05:07 +0800 | [diff] [blame] | 1186 | #endif |
Mate Toth-Pal | 3ad2e3e | 2019-07-11 21:43:37 +0200 | [diff] [blame] | 1187 | .partitions = partition_list, |
| 1188 | }; |
| 1189 | |
| 1190 | #endif /* __TFM_SPM_DB_INC__ */ |