]> begriffs open source - freertos/blob - portable/IAR/ARM_CM33/secure/secure_init.h
Add SMP in the License Header (#402)
[freertos] / portable / IAR / ARM_CM33 / secure / secure_init.h
1 /*
2  * FreeRTOS SMP Kernel V202110.00
3  * Copyright (C) 2020 Amazon.com, Inc. or its affiliates.  All Rights Reserved.
4  *
5  * Permission is hereby granted, free of charge, to any person obtaining a copy of
6  * this software and associated documentation files (the "Software"), to deal in
7  * the Software without restriction, including without limitation the rights to
8  * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9  * the Software, and to permit persons to whom the Software is furnished to do so,
10  * subject to the following conditions:
11  *
12  * The above copyright notice and this permission notice shall be included in all
13  * copies or substantial portions of the Software.
14  *
15  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17  * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18  * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19  * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21  *
22  * https://www.FreeRTOS.org
23  * https://github.com/FreeRTOS
24  *
25  * 1 tab == 4 spaces!
26  */
27
28 #ifndef __SECURE_INIT_H__
29 #define __SECURE_INIT_H__
30
31 /**
32  * @brief De-prioritizes the non-secure exceptions.
33  *
34  * This is needed to ensure that the non-secure PendSV runs at the lowest
35  * priority. Context switch is done in the non-secure PendSV handler.
36  *
37  * @note This function must be called in the handler mode. It is no-op if called
38  * in the thread mode.
39  */
40 void SecureInit_DePrioritizeNSExceptions( void );
41
42 /**
43  * @brief Sets up the Floating Point Unit (FPU) for Non-Secure access.
44  *
45  * Also sets FPCCR.TS=1 to ensure that the content of the Floating Point
46  * Registers are not leaked to the non-secure side.
47  *
48  * @note This function must be called in the handler mode. It is no-op if called
49  * in the thread mode.
50  */
51 void SecureInit_EnableNSFPUAccess( void );
52
53 #endif /* __SECURE_INIT_H__ */