Skip to content

Commit

Permalink
hpmicro: set EXCEPTION_SECTION to .isr_vector section
Browse files Browse the repository at this point in the history
Signed-off-by: Zhihong Chen <zhihong.chen@hpmicro.com>
chenzhihong007 committed Aug 2, 2024
1 parent 2ab3047 commit 7d9ab7c
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion arch/risc-v/src/common/riscv_vectors.S
Original file line number Diff line number Diff line change
@@ -22,7 +22,7 @@
* Included Files
****************************************************************************/

.section .text
.section .vector_table
.balign 8
.global __trap_vec

8 changes: 8 additions & 0 deletions arch/risc-v/src/hpmicro/chip.h
Original file line number Diff line number Diff line change
@@ -27,4 +27,12 @@

#include <nuttx/config.h>

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/

/* Section for exception handler. */

#define EXCEPTION_SECTION .isr_vector

#endif /* __ARCH_RISCV_SRC_HPMICRO_CHIP_H */
2 changes: 1 addition & 1 deletion arch/risc-v/src/hpmicro/hpm_irq_dispatch.c
Original file line number Diff line number Diff line change
@@ -51,7 +51,7 @@ int g_vector;
* riscv_dispatch_irq
****************************************************************************/

void *riscv_dispatch_irq(uintptr_t vector, uintptr_t *regs)
ATTR_RAMFUNC void *riscv_dispatch_irq(uintptr_t vector, uintptr_t *regs)
{
int irq = (vector >> RV_IRQ_MASK) | (vector & 0xf);

0 comments on commit 7d9ab7c

Please sign in to comment.