TF-M Reference Manual  1.2.0
TrustedFirmware-M
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
core_test_defs.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017-2020, Arm Limited. All rights reserved.
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  *
6  */
7 
8 #ifndef __CORE_TEST_DEFS_H__
9 #define __CORE_TEST_DEFS_H__
10 
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
14 
15 #include <inttypes.h>
16 #include <limits.h>
17 #include "tfm_api.h"
18 
19 /* These definitions are used in symbols, only digits are permitted */
20 #define CORE_TEST_ID_NS_THREAD 1001
21 #define CORE_TEST_ID_CHECK_INIT 1003
22 #define CORE_TEST_ID_RECURSION 1004
23 #define CORE_TEST_ID_BUFFER_CHECK 1007
24 #define CORE_TEST_ID_SS_TO_SS 1008
25 #define CORE_TEST_ID_SS_TO_SS_BUFFER 1010
26 #define CORE_TEST_ID_PERIPHERAL_ACCESS 1012
27 #define CORE_TEST_ID_GET_CALLER_CLIENT_ID 1013
28 #define CORE_TEST_ID_SPM_REQUEST 1014
29 #define CORE_TEST_ID_IOVEC_SANITIZATION 1015
30 #define CORE_TEST_ID_OUTVEC_WRITE 1016
31 #define CORE_TEST_ID_SECURE_IRQ 1017
32 #define CORE_TEST_ID_BLOCK 2001
33 
41 };
42 
44  volatile int32_t timer0_triggered;
45  volatile int32_t timer1_triggered;
46 };
47 
48 /* Use lower 16 bits in return value for error code, upper 16 for line number
49  * in test service
50  */
51 #define CORE_TEST_RETURN_ERROR(x) return (((__LINE__) << 16) | x)
52 #define CORE_TEST_ERROR_GET_EXTRA(x) (x >> 16)
53 #define CORE_TEST_ERROR_GET_CODE(x) (x & 0xFFFF)
54 
69 
71 
73 
74  /* Following entry is only to ensure the error code of int size */
76 };
77 
78 #ifdef __cplusplus
79 }
80 #endif
81 
82 #endif /* __CORE_TEST_DEFS_H__ */
volatile int32_t timer1_triggered
core_test_errno_t
irq_test_scenario_t
volatile int32_t timer0_triggered