fix: L0 GN compilation problem
Close: #I3ORHS Change-Id: Ia105084336f2ba66f91546226a9383646a0148ce
This commit is contained in:
parent
1f725147f3
commit
2f9bfcc6ee
|
@ -29,12 +29,11 @@
|
||||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define _GNU_SOURCE 1
|
||||||
#include "ff.h"
|
#include "ff.h"
|
||||||
#if FF_USE_EXPAND
|
|
||||||
#define _GNU_SOURCE
|
|
||||||
#endif
|
|
||||||
#include "fatfs.h"
|
#include "fatfs.h"
|
||||||
#include "errno.h"
|
#include "errno.h"
|
||||||
|
#include "stdbool.h"
|
||||||
#include "limits.h"
|
#include "limits.h"
|
||||||
#include "pthread.h"
|
#include "pthread.h"
|
||||||
#include "time.h"
|
#include "time.h"
|
||||||
|
|
|
@ -19,6 +19,7 @@ extern "C" {
|
||||||
#define __NEED_mbstate_t
|
#define __NEED_mbstate_t
|
||||||
|
|
||||||
#if __STDC_VERSION__ < 201112L
|
#if __STDC_VERSION__ < 201112L
|
||||||
|
#define __NEED_off_t
|
||||||
#define __NEED_struct__IO_FILE
|
#define __NEED_struct__IO_FILE
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -490,6 +490,16 @@ LITE_OS_SEC_TEXT_INIT VOID HalExcHandleEntry(UINT32 excType, UINT32 faultAddr, U
|
||||||
HalSysExit();
|
HalSysExit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* stack protector */
|
||||||
|
WEAK UINT32 __stack_chk_guard = 0xd00a0dff;
|
||||||
|
|
||||||
|
WEAK VOID __stack_chk_fail(VOID)
|
||||||
|
{
|
||||||
|
/* __builtin_return_address is a builtin function, building in gcc */
|
||||||
|
LOS_Panic("stack-protector: Kernel stack is corrupted in: %p\n",
|
||||||
|
__builtin_return_address(0));
|
||||||
|
}
|
||||||
|
|
||||||
/* ****************************************************************************
|
/* ****************************************************************************
|
||||||
Function : HalHwiInit
|
Function : HalHwiInit
|
||||||
Description : initialization of the hardware interrupt
|
Description : initialization of the hardware interrupt
|
||||||
|
|
|
@ -62,6 +62,11 @@ typedef VOID (*HWI_PROC_FUNC)(VOID *parm);
|
||||||
typedef VOID (*HWI_PROC_FUNC)(void);
|
typedef VOID (*HWI_PROC_FUNC)(void);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* stack protector */
|
||||||
|
extern UINT32 __stack_chk_guard;
|
||||||
|
|
||||||
|
extern VOID __stack_chk_fail(VOID);
|
||||||
|
|
||||||
UINT32 HalIsIntActive(VOID);
|
UINT32 HalIsIntActive(VOID);
|
||||||
#define OS_INT_ACTIVE (HalIsIntActive())
|
#define OS_INT_ACTIVE (HalIsIntActive())
|
||||||
#define OS_INT_INACTIVE (!(OS_INT_ACTIVE))
|
#define OS_INT_INACTIVE (!(OS_INT_ACTIVE))
|
||||||
|
|
|
@ -31,6 +31,7 @@ static_library("utils") {
|
||||||
sources = [
|
sources = [
|
||||||
"los_debug.c",
|
"los_debug.c",
|
||||||
"los_error.c",
|
"los_error.c",
|
||||||
|
"los_hook.c",
|
||||||
]
|
]
|
||||||
|
|
||||||
include_dirs = [
|
include_dirs = [
|
||||||
|
|
Loading…
Reference in New Issue