1 /* 2 * Copyright (c) 2001-2019, Arm Limited and Contributors. All rights reserved. 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 7 8 9 /************* Include Files ****************/ 10 #include "cc_pal_init.h" 11 #include "cc_pal_dma_plat.h" 12 #include "cc_pal_log.h" 13 #include "cc_pal_mutex.h" 14 #include "cc_pal_pm.h" 15 16 /** 17 * @brief PAL layer entry point. 18 * The function initializes customer platform sub components, 19 * such as memory mapping used later by CRYS to get physical contiguous memory. 20 * 21 * 22 * @return Returns a non-zero value in case of failure 23 */ CC_PalInit(void)24int CC_PalInit(void) 25 { // IG - need to use palInit of cc_linux for all PALs 26 uint32_t rc = CC_OK; 27 28 CC_PalLogInit(); 29 30 rc = CC_PalDmaInit(0, 0); 31 if (rc != CC_OK) { 32 return rc; 33 } 34 35 #ifdef CC_IOT 36 /* Initialize power management module */ 37 CC_PalPowerSaveModeInit(); 38 #endif 39 40 return rc; 41 } 42 43 44 /** 45 * @brief PAL layer entry point. 46 * The function initializes customer platform sub components, 47 * such as memory mapping used later by CRYS to get physical contiguous memory. 48 * 49 * 50 * @return None 51 */ CC_PalTerminate(void)52void CC_PalTerminate(void) 53 { 54 CC_PalDmaTerminate(); 55 } 56 57