1 /* 2 * Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved. 3 * Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without modification, 6 * are permitted provided that the following conditions are met: 7 * 8 * 1. Redistributions of source code must retain the above copyright notice, this list of 9 * conditions and the following disclaimer. 10 * 11 * 2. Redistributions in binary form must reproduce the above copyright notice, this list 12 * of conditions and the following disclaimer in the documentation and/or other materials 13 * provided with the distribution. 14 * 15 * 3. Neither the name of the copyright holder nor the names of its contributors may be used 16 * to endorse or promote products derived from this software without specific prior written 17 * permission. 18 * 19 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 22 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR 23 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 24 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 28 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 29 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 */ 31 #ifndef IT_LOS_SWTMR_H 32 #define IT_LOS_SWTMR_H 33 34 #include "osTest.h" 35 36 #ifdef __cplusplus 37 #if __cplusplus 38 extern "C" { 39 #endif /* __cplusplus */ 40 #endif /* __cplusplus */ 41 42 #define SELF_DELETED 0 43 #define SYS_EXIST_SWTMR 1 44 #define TEST_HWI_RUNTIME 0x100000 45 46 extern EVENT_CB_S g_eventCB0; 47 extern EVENT_CB_S g_eventCB1; 48 extern EVENT_CB_S g_eventCB2; 49 extern EVENT_CB_S g_eventCB3; 50 51 #define TIMER_LOS_EXPIRATION3 10 52 #define TIMER_LOS_EXPIRATION1 4 53 54 #define TIMER_LOS_HANDLER_PARAMETER 0xFF 55 #define TIMER_LOS_SELF_DELETED 1 56 57 extern UINT32 g_idleTaskID; 58 59 static UINT32 g_swtmrId1; 60 static UINT32 g_swtmrId2; 61 static UINT32 g_swtmrId3; 62 63 static UINT32 g_swtmrCountA; 64 static UINT32 g_swtmrCountB; 65 static UINT32 g_swtmrCountC; 66 67 static UINT32 g_uwsTick1; 68 static UINT32 g_uwsTick2; 69 static UINT32 g_uwsTick3; 70 71 extern VOID LOS_GetCpuTick(UINT32 *puwCntHi, UINT32 *puwCntLo); 72 extern VOID ItSuiteLosSwtmr(VOID); 73 extern VOID ItLosSwtmr001(VOID); 74 extern VOID ItLosSwtmr002(VOID); 75 extern VOID ItLosSwtmr003(VOID); 76 extern VOID ItLosSwtmr004(VOID); 77 extern VOID ItLosSwtmr005(VOID); 78 extern VOID ItLosSwtmr006(VOID); 79 extern VOID ItLosSwtmr007(VOID); 80 extern VOID ItLosSwtmr008(VOID); 81 extern VOID ItLosSwtmr009(VOID); 82 extern VOID ItLosSwtmr010(VOID); 83 extern VOID ItLosSwtmr011(VOID); 84 extern VOID ItLosSwtmr012(VOID); 85 extern VOID ItLosSwtmr013(VOID); 86 extern VOID ItLosSwtmr014(VOID); 87 extern VOID ItLosSwtmr015(VOID); 88 extern VOID ItLosSwtmr016(VOID); 89 extern VOID ItLosSwtmr017(VOID); 90 extern VOID ItLosSwtmr018(VOID); 91 extern VOID ItLosSwtmr019(VOID); 92 extern VOID ItLosSwtmr020(VOID); 93 extern VOID ItLosSwtmr021(VOID); 94 extern VOID ItLosSwtmr022(VOID); 95 extern VOID ItLosSwtmr023(VOID); 96 extern VOID ItLosSwtmr024(VOID); 97 extern VOID ItLosSwtmr025(VOID); 98 extern VOID ItLosSwtmr026(VOID); 99 extern VOID ItLosSwtmr027(VOID); 100 extern VOID ItLosSwtmr028(VOID); 101 extern VOID ItLosSwtmr029(VOID); 102 extern VOID ItLosSwtmr030(VOID); 103 extern VOID ItLosSwtmr031(VOID); 104 extern VOID ItLosSwtmr032(VOID); 105 extern VOID ItLosSwtmr033(VOID); 106 extern VOID ItLosSwtmr034(VOID); 107 extern VOID ItLosSwtmr035(VOID); 108 extern VOID ItLosSwtmr036(VOID); 109 extern VOID ItLosSwtmr037(VOID); 110 extern VOID ItLosSwtmr038(VOID); 111 extern VOID ItLosSwtmr039(VOID); 112 extern VOID ItLosSwtmr040(VOID); 113 extern VOID ItLosSwtmr041(VOID); 114 extern VOID ItLosSwtmr042(VOID); 115 extern VOID ItLosSwtmr043(VOID); 116 extern VOID ItLosSwtmr044(VOID); 117 extern VOID ItLosSwtmr045(VOID); 118 extern VOID ItLosSwtmr046(VOID); 119 extern VOID ItLosSwtmr047(VOID); 120 extern VOID ItLosSwtmr048(VOID); 121 extern VOID ItLosSwtmr049(VOID); 122 extern VOID ItLosSwtmr050(VOID); 123 extern VOID ItLosSwtmr051(VOID); 124 extern VOID ItLosSwtmr052(VOID); 125 extern VOID ItLosSwtmr053(VOID); 126 extern VOID ItLosSwtmr054(VOID); 127 extern VOID ItLosSwtmr055(VOID); 128 extern VOID ItLosSwtmr056(VOID); 129 extern VOID ItLosSwtmr057(VOID); 130 extern VOID ItLosSwtmr058(VOID); 131 extern VOID ItLosSwtmr059(VOID); 132 extern VOID ItLosSwtmr060(VOID); 133 extern VOID ItLosSwtmr061(VOID); 134 extern VOID ItLosSwtmr062(VOID); 135 extern VOID ItLosSwtmr063(VOID); 136 extern VOID ItLosSwtmr064(VOID); 137 extern VOID ItLosSwtmr065(VOID); 138 extern VOID ItLosSwtmr066(VOID); 139 extern VOID ItLosSwtmr067(VOID); 140 extern VOID ItLosSwtmr068(VOID); 141 extern VOID ItLosSwtmr069(VOID); 142 extern VOID ItLosSwtmr071(VOID); 143 extern VOID ItLosSwtmr072(VOID); 144 extern VOID ItLosSwtmr073(VOID); 145 extern VOID ItLosSwtmr074(VOID); 146 extern VOID ItLosSwtmr075(VOID); 147 extern VOID ItLosSwtmr076(VOID); 148 extern VOID ItLosSwtmr077(VOID); 149 extern VOID ItLosSwtmr078(VOID); 150 extern VOID ItLosSwtmr079(VOID); 151 extern VOID ItLosSwtmr080(VOID); 152 extern VOID ItLosSwtmr081(VOID); 153 154 extern VOID ItLosSwtmrAlign001(VOID); 155 extern VOID ItLosSwtmrAlign002(VOID); 156 extern VOID ItLosSwtmrAlign003(VOID); 157 extern VOID ItLosSwtmrAlign004(VOID); 158 extern VOID ItLosSwtmrAlign005(VOID); 159 extern VOID ItLosSwtmrAlign006(VOID); 160 extern VOID ItLosSwtmrAlign007(VOID); 161 extern VOID ItLosSwtmrAlign008(VOID); 162 extern VOID ItLosSwtmrAlign009(VOID); 163 extern VOID ItLosSwtmrAlign010(VOID); 164 extern VOID ItLosSwtmrAlign011(VOID); 165 extern VOID ItLosSwtmrAlign012(VOID); 166 extern VOID ItLosSwtmrAlign013(VOID); 167 extern VOID ItLosSwtmrAlign014(VOID); 168 extern VOID ItLosSwtmrAlign015(VOID); 169 extern VOID ItLosSwtmrAlign016(VOID); 170 extern VOID ItLosSwtmrAlign017(VOID); 171 extern VOID ItLosSwtmrAlign018(VOID); 172 extern VOID ItLosSwtmrAlign019(VOID); 173 extern VOID ItLosSwtmrAlign020(VOID); 174 extern VOID ItLosSwtmrAlign021(VOID); 175 extern VOID ItLosSwtmrAlign022(VOID); 176 extern VOID ItLosSwtmrAlign023(VOID); 177 extern VOID ItLosSwtmrAlign024(VOID); 178 extern VOID ItLosSwtmrAlign025(VOID); 179 extern VOID ItLosSwtmrAlign026(VOID); 180 extern VOID ItLosSwtmrAlign027(VOID); 181 extern VOID ItLosSwtmrAlign028(VOID); 182 extern VOID ItLosSwtmrAlign029(VOID); 183 extern VOID ItLosSwtmrAlign030(VOID); 184 extern VOID ItLosSwtmrAlign031(VOID); 185 extern VOID ItLosSwtmrDelay001(VOID); 186 extern VOID ItLosSwtmrDelay002(VOID); 187 extern VOID ItLosSwtmrDelay003(VOID); 188 extern VOID ItLosSwtmrDelay004(VOID); 189 extern VOID ItLosSwtmrDelay005(VOID); 190 191 192 #ifdef __cplusplus 193 #if __cplusplus 194 } 195 #endif /* __cplusplus */ 196 #endif /* __cplusplus */ 197 198 #endif /* IT_LOS_SWTMR_H */