summaryrefslogtreecommitdiffstats
path: root/bsps/riscv/riscv/start/start.S
diff options
context:
space:
mode:
Diffstat (limited to 'bsps/riscv/riscv/start/start.S')
-rw-r--r--bsps/riscv/riscv/start/start.S6
1 files changed, 6 insertions, 0 deletions
diff --git a/bsps/riscv/riscv/start/start.S b/bsps/riscv/riscv/start/start.S
index 3674a4bdb5..58bc57dc12 100644
--- a/bsps/riscv/riscv/start/start.S
+++ b/bsps/riscv/riscv/start/start.S
@@ -46,6 +46,12 @@ PUBLIC(_start)
TYPE_FUNC(_start)
SYM(_start):
+ /* Load global pointer */
+ .option push
+ .option norelax
+ la gp, __global_pointer$
+ .option pop
+
la t0, ISR_Handler
csrw mtvec, t0