1 /*
2  * Copyright 2021-2023 NXP
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  */
6 
7 #ifndef LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_H
8 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_H
9 
10 /**
11 *   @file    Linflexd_Uart_Ip_TrustedFunctions.h
12 *
13 *
14 *   @brief   LINFLEXD_UART IP driver header file.
15 *   @details LINFLEXD_UART IP driver header file.
16 
17 *   @addtogroup  linflexd_uart_ip Linflexd UART IPL
18 *   @{
19 */
20 
21 #ifdef __cplusplus
22 extern "C"{
23 #endif
24 
25 
26 
27 /*==================================================================================================
28 *                                        INCLUDE FILES
29 * 1) system and project includes
30 * 2) needed interfaces from external units
31 * 3) internal and external interfaces from this unit
32 ==================================================================================================*/
33 #include "Linflexd_Uart_Ip_Defines.h"
34 /*==================================================================================================
35 *                              SOURCE FILE VERSION INFORMATION
36 ==================================================================================================*/
37 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_VENDOR_ID                       43
38 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_AR_RELEASE_MAJOR_VERSION        4
39 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_AR_RELEASE_MINOR_VERSION        7
40 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_AR_RELEASE_REVISION_VERSION     0
41 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_SW_MAJOR_VERSION                1
42 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_SW_MINOR_VERSION                0
43 #define LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_SW_PATCH_VERSION                0
44 /*==================================================================================================
45 *                                     FILE VERSION CHECKS
46 ==================================================================================================*/
47 /* Check if Linflexd_Uart_Ip_TrustedFunctions.h header file and Linflexd_Uart_Ip_Defines.h configuration header file are of the same vendor */
48 #if (LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_VENDOR_ID != LINFLEXD_UART_IP_DEFINES_VENDOR_ID)
49     #error "Linflexd_Uart_Ip_TrustedFunctions.h and Linflexd_Uart_Ip_Defines.h have different vendor IDs"
50 #endif
51     /* Check if Linflexd_Uart_Ip_TrustedFunctions.h header file and Linflexd_Uart_Ip_Defines.h configuration header file are of the same Autosar version */
52 #if ((LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_AR_RELEASE_MAJOR_VERSION != LINFLEXD_UART_IP_DEFINES_AR_RELEASE_MAJOR_VERSION) || \
53      (LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_AR_RELEASE_MINOR_VERSION != LINFLEXD_UART_IP_DEFINES_AR_RELEASE_MINOR_VERSION) || \
54      (LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_AR_RELEASE_REVISION_VERSION != LINFLEXD_UART_IP_AR_RELEASE_REVISION_VERSION) \
55     )
56 #error "AutoSar Version Numbers of Linflexd_Uart_Ip_TrustedFunctions.h and Linflexd_Uart_Ip_Defines.h are different"
57 #endif
58 /* Check if Linflexd_Uart_Ip_TrustedFunctions.h header file and Linflexd_Uart_Ip_Defines.h configuration header file are of the same software version */
59 #if ((LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_SW_MAJOR_VERSION != LINFLEXD_UART_IP_DEFINES_SW_MAJOR_VERSION) || \
60      (LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_SW_MINOR_VERSION != LINFLEXD_UART_IP_DEFINES_SW_MINOR_VERSION) || \
61      (LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_SW_PATCH_VERSION != LINFLEXD_UART_IP_DEFINES_SW_PATCH_VERSION) \
62     )
63 #error "Software Version Numbers of Linflexd_Uart_Ip_TrustedFunctions.h and Linflexd_Uart_Ip_Defines.h are different"
64 #endif
65 /*==================================================================================================
66 *                                          CONSTANTS
67 ==================================================================================================*/
68 /*==================================================================================================
69 *                                      DEFINES AND MACROS
70 ==================================================================================================*/
71 /*==================================================================================================
72 *                                            ENUMS
73 ==================================================================================================*/
74 /*==================================================================================================
75 *                                STRUCTURES AND OTHER TYPEDEFS
76 ==================================================================================================*/
77 /*==================================================================================================
78 *                                GLOBAL VARIABLE DECLARATIONS
79 ==================================================================================================*/
80 
81 /*==================================================================================================
82 *                                    FUNCTION PROTOTYPES
83 ==================================================================================================*/
84 #define UART_START_SEC_CODE
85 #include "Uart_MemMap.h"
86 
87 #ifdef LINFLEXD_UART_IP_SET_USER_ACCESS_ALLOWED_AVAILABLE
88 #if (STD_ON == LINFLEXD_UART_IP_SET_USER_ACCESS_ALLOWED_AVAILABLE)
89 /**
90 * @brief            This function will set UAA bit in REG_PROT for UART unit
91 * @details          This function will set UAA bit in REG_PROT for UART unit
92 *
93 * @param[in]        Instance - LINFLEXD_UART peripheral instance number.
94 *
95 * @return           void.
96 */
97 extern void Linflexd_Uart_Ip_SetUserAccess(const uint8 Instance);
98 
99 #endif /* (STD_ON == LINFLEXD_UART_IP_SET_USER_ACCESS_ALLOWED_AVAILABLE) */
100 #endif /* ifdef LINFLEXD_UART_IP_SET_USER_ACCESS_ALLOWED_AVAILABLE */
101 
102 #define UART_STOP_SEC_CODE
103 #include "Uart_MemMap.h"
104 
105 #ifdef __cplusplus
106 }
107 #endif
108 
109 /** @} */
110 
111 #endif /* LINFLEXD_UART_IP_TRUSTEDFUNCTIONS_H */
112