1 /* 2 * Copyright (c) 2015, Freescale Semiconductor, Inc. 3 * Copyright 2016-2018 NXP 4 * All rights reserved. 5 * 6 * SPDX-License-Identifier: BSD-3-Clause 7 */ 8 9 #ifndef _BOARD_H_ 10 #define _BOARD_H_ 11 12 #include <rtthread.h> 13 14 #include "clock_config.h" 15 #include "fsl_gpio.h" 16 17 #if defined(__ARMCC_VERSION) 18 extern int Image$$ARM_LIB_HEAP$$ZI$$Base; 19 extern int Image$$ARM_LIB_STACK$$ZI$$Base; 20 #define HEAP_BEGIN ((void *)&Image$$ARM_LIB_HEAP$$ZI$$Base) 21 #define HEAP_END ((void*)&Image$$ARM_LIB_STACK$$ZI$$Base) 22 #elif defined(__ICCARM__) 23 #pragma section="HEAP" 24 #define HEAP_BEGIN (__section_begin("HEAP")) 25 #define HEAP_END (__section_end("HEAP")) 26 #elif defined(__GNUC__) 27 extern int __HeapBase; 28 extern int __HeapLimit; 29 #define HEAP_BEGIN ((void *)&__HeapBase) 30 #define HEAP_END ((void *)&__HeapLimit) 31 #endif 32 33 void rt_hw_board_init(void); 34 35 36 #if defined(__cplusplus) 37 } 38 #endif /* __cplusplus */ 39 40 #endif /* _BOARD_H_ */ 41