1 /* 2 * Copyright 2020-2023 NXP 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 /** 7 * @file Clock_Ip_Irq.c 8 * @version 2.0.0 9 * 10 * @brief CLOCK driver implementations. 11 * @details CLOCK driver implementations. 12 * 13 * @addtogroup CLOCK_DRIVER Clock Ip Driver 14 * @{ 15 */ 16 17 #ifdef __cplusplus 18 extern "C"{ 19 #endif 20 21 22 /*================================================================================================== 23 * INCLUDE FILES 24 * 1) system and project includes 25 * 2) needed interfaces from external units 26 * 3) internal and external interfaces from this unit 27 ==================================================================================================*/ 28 #include "Clock_Ip_Private.h" 29 /*================================================================================================== 30 SOURCE FILE VERSION INFORMATION 31 ==================================================================================================*/ 32 #define CLOCK_IP_IRQ_VENDOR_ID_C 43 33 #define CLOCK_IP_IRQ_AR_RELEASE_MAJOR_VERSION_C 4 34 #define CLOCK_IP_IRQ_AR_RELEASE_MINOR_VERSION_C 7 35 #define CLOCK_IP_IRQ_AR_RELEASE_REVISION_VERSION_C 0 36 #define CLOCK_IP_IRQ_SW_MAJOR_VERSION_C 2 37 #define CLOCK_IP_IRQ_SW_MINOR_VERSION_C 0 38 #define CLOCK_IP_IRQ_SW_PATCH_VERSION_C 0 39 40 /*================================================================================================== 41 * FILE VERSION CHECKS 42 ==================================================================================================*/ 43 /* Check if Clock_Ip_Irq.c file and Clock_Ip_Private.h file are of the same vendor */ 44 #if (CLOCK_IP_IRQ_VENDOR_ID_C != CLOCK_IP_PRIVATE_VENDOR_ID) 45 #error "Clock_Ip_Irq.c and Clock_Ip_Private.h have different vendor ids" 46 #endif 47 48 /* Check if Clock_Ip_Irq.c file and Clock_Ip_Private.h file are of the same Autosar version */ 49 #if ((CLOCK_IP_IRQ_AR_RELEASE_MAJOR_VERSION_C != CLOCK_IP_PRIVATE_AR_RELEASE_MAJOR_VERSION) || \ 50 (CLOCK_IP_IRQ_AR_RELEASE_MINOR_VERSION_C != CLOCK_IP_PRIVATE_AR_RELEASE_MINOR_VERSION) || \ 51 (CLOCK_IP_IRQ_AR_RELEASE_REVISION_VERSION_C != CLOCK_IP_PRIVATE_AR_RELEASE_REVISION_VERSION) \ 52 ) 53 #error "AutoSar Version Numbers of Clock_Ip_Irq.c and Clock_Ip_Private.h are different" 54 #endif 55 56 /* Check if Clock_Ip_Irq.c file and Clock_Ip_Private.h file are of the same Software version */ 57 #if ((CLOCK_IP_IRQ_SW_MAJOR_VERSION_C != CLOCK_IP_PRIVATE_SW_MAJOR_VERSION) || \ 58 (CLOCK_IP_IRQ_SW_MINOR_VERSION_C != CLOCK_IP_PRIVATE_SW_MINOR_VERSION) || \ 59 (CLOCK_IP_IRQ_SW_PATCH_VERSION_C != CLOCK_IP_PRIVATE_SW_PATCH_VERSION) \ 60 ) 61 #error "Software Version Numbers of Clock_Ip_Irq.c and Clock_Ip_Private.h are different" 62 #endif 63 /*================================================================================================== 64 * LOCAL TYPEDEFS (STRUCTURES, UNIONS, ENUMS) 65 ==================================================================================================*/ 66 67 /*================================================================================================== 68 * LOCAL MACROS 69 ==================================================================================================*/ 70 71 /*================================================================================================== 72 * LOCAL CONSTANTS 73 ==================================================================================================*/ 74 75 /*================================================================================================== 76 * LOCAL VARIABLES 77 ==================================================================================================*/ 78 79 /*================================================================================================== 80 * GLOBAL CONSTANTS 81 ==================================================================================================*/ 82 83 /*================================================================================================== 84 * GLOBAL VARIABLES 85 ==================================================================================================*/ 86 87 /*================================================================================================== 88 * LOCAL FUNCTION PROTOTYPES 89 ==================================================================================================*/ 90 91 /*================================================================================================== 92 * LOCAL FUNCTIONS 93 ==================================================================================================*/ 94 95 /*================================================================================================== 96 * GLOBAL FUNCTIONS 97 ==================================================================================================*/ 98 #define MCU_START_SEC_CODE 99 100 #include "Mcu_MemMap.h" 101 #if CLOCK_IP_CMU_INSTANCES_ARRAY_SIZE > 0U 102 ISR(Mcu_Cmu_ClockFail_IRQHandler); 103 104 /** 105 * @brief This function clear the CMU interrupt flag from CMU module. 106 * @details Called by RGM ISR routine when a user notification for CMU FCCU events is configured 107 * 108 * @return void 109 * 110 */ ISR(Mcu_Cmu_ClockFail_IRQHandler)111ISR(Mcu_Cmu_ClockFail_IRQHandler) 112 { 113 Clock_Ip_CMU_ClockFailInt(); 114 EXIT_INTERRUPT(); 115 } 116 #endif 117 118 119 #define MCU_STOP_SEC_CODE 120 121 #include "Mcu_MemMap.h" 122 123 #ifdef __cplusplus 124 } 125 #endif 126 127 /** @} */ 128