Fix compiling eror in hpmicro bsp (#8889)

- added 'DEVICE' to rtconfig.py
- fixed compiling error cuased by change in interrupt_gcc.S

Signed-off-by: Fan YANG <fan.yang@hpmicro.com>
This commit is contained in:
Fan Yang 2024-04-30 20:11:47 +08:00 committed by GitHub
parent 0ccc315bce
commit c21ba6985d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 18 additions and 5 deletions

View File

@ -66,7 +66,8 @@ if PLATFORM == 'gcc':
STRIP = PREFIX + 'strip'
ARCH_ABI = ' -mcmodel=medlow '
CFLAGS = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
DEVICE = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
CFLAGS = DEVICE
AFLAGS = CFLAGS
LFLAGS = ARCH_ABI + ' --specs=nano.specs --specs=nosys.specs -u _printf_float -u _scanf_float -nostartfiles -Wl,--gc-sections '

View File

@ -66,7 +66,8 @@ if PLATFORM == 'gcc':
STRIP = PREFIX + 'strip'
ARCH_ABI = ' -mcmodel=medlow '
CFLAGS = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
DEVICE = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
CFLAGS = DEVICE
AFLAGS = CFLAGS
LFLAGS = ARCH_ABI + ' --specs=nano.specs --specs=nosys.specs -u _printf_float -u _scanf_float -nostartfiles -Wl,--gc-sections '

View File

@ -66,7 +66,8 @@ if PLATFORM == 'gcc':
STRIP = PREFIX + 'strip'
ARCH_ABI = ' -mcmodel=medlow '
CFLAGS = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
DEVICE = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
CFLAGS = DEVICE
AFLAGS = CFLAGS
LFLAGS = ARCH_ABI + ' --specs=nano.specs --specs=nosys.specs -u _printf_float -u _scanf_float -nostartfiles -Wl,--gc-sections '

View File

@ -66,7 +66,8 @@ if PLATFORM == 'gcc':
STRIP = PREFIX + 'strip'
ARCH_ABI = ' -mcmodel=medlow '
CFLAGS = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
DEVICE = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
CFLAGS = DEVICE
AFLAGS = CFLAGS
LFLAGS = ARCH_ABI + ' --specs=nano.specs --specs=nosys.specs -u _printf_float -u _scanf_float -nostartfiles -Wl,--gc-sections '

View File

@ -66,7 +66,8 @@ if PLATFORM == 'gcc':
STRIP = PREFIX + 'strip'
ARCH_ABI = ' -mcmodel=medlow '
CFLAGS = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
DEVICE = ARCH_ABI + ' -DUSE_NONVECTOR_MODE=1 ' + ' -ffunction-sections -fdata-sections -fno-common '
CFLAGS = DEVICE
AFLAGS = CFLAGS
LFLAGS = ARCH_ABI + ' --specs=nano.specs --specs=nosys.specs -u _printf_float -u _scanf_float -nostartfiles -Wl,--gc-sections '

View File

@ -214,6 +214,7 @@ SW_handler:
.section .text.trap_entry
.align 2
.weak trap_entry
.global trap_entry
trap_entry:
#ifdef ARCH_RISCV_FPU

View File

@ -109,3 +109,10 @@ rt_weak void rt_show_stack_frame(void)
rt_kprintf("t6 : 0x%08x\r\n", s_stack_frame->t6);
#endif
}
/**
* Trap Handler
*/
rt_weak void handle_trap(rt_uint32_t mcause, rt_uint32_t mepc, rt_uint32_t sp)
{
}