1 /**************************************************************************/
2 /*                                                                        */
3 /*       Copyright (c) Microsoft Corporation. All rights reserved.        */
4 /*                                                                        */
5 /*       This software is licensed under the Microsoft Software License   */
6 /*       Terms for Microsoft Azure RTOS. Full text of the license can be  */
7 /*       found in the LICENSE file at https://aka.ms/AzureRTOS_EULA       */
8 /*       and in the root directory of this software.                      */
9 /*                                                                        */
10 /**************************************************************************/
11 
12 
13 /**************************************************************************/
14 /**************************************************************************/
15 /**                                                                       */
16 /** ThreadX Component                                                     */
17 /**                                                                       */
18 /**   Thread                                                              */
19 /**                                                                       */
20 /**************************************************************************/
21 /**************************************************************************/
22 
23 
24 /**************************************************************************/
25 /*                                                                        */
26 /*  COMPONENT DEFINITION                                   RELEASE        */
27 /*                                                                        */
28 /*    tx_secure_interface.h                               PORTABLE C      */
29 /*                                                            6.1         */
30 /*  AUTHOR                                                                */
31 /*                                                                        */
32 /*    Scott Larson, Microsoft Corporation                                 */
33 /*                                                                        */
34 /*  DESCRIPTION                                                           */
35 /*                                                                        */
36 /*    This file defines the ThreadX secure thread stack components,       */
37 /*    including data types and external references.                       */
38 /*    It is assumed that tx_api.h and tx_port.h have already been         */
39 /*    included.                                                           */
40 /*                                                                        */
41 /*  RELEASE HISTORY                                                       */
42 /*                                                                        */
43 /*    DATE              NAME                      DESCRIPTION             */
44 /*                                                                        */
45 /*  09-30-2020      Scott Larson            Initial Version 6.1           */
46 /*                                                                        */
47 /**************************************************************************/
48 
49 #ifndef TX_SECURE_INTERFACE_H
50 #define TX_SECURE_INTERFACE_H
51 
52 /* Define internal secure thread stack function prototypes.  */
53 
54 extern UINT    _tx_thread_secure_mode_stack_initialize(void);
55 extern UINT    _tx_thread_secure_mode_stack_allocate(TX_THREAD *thread_ptr, ULONG stack_size);
56 extern UINT    _tx_thread_secure_mode_stack_free(TX_THREAD *thread_ptr);
57 extern void    _tx_thread_secure_stack_initialize(void);
58 extern void    _tx_thread_secure_stack_context_save(TX_THREAD *thread_ptr);
59 extern void    _tx_thread_secure_stack_context_restore(TX_THREAD *thread_ptr);
60 
61 #endif
62