Files
eb001/tb/sw/src/slvStartup.S

43 lines
677 B
ArmAsm
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#include "custom_ops.S"
.extern main
.globl _prog_start
.section .text.init
_prog_start:
li sp, 0
picorv32_maskirq_insn(zero, zero)
call main
ecall
.balign 32
.section .trap_entry, "ax", %progbits
trap_entry:
# q0 return address
# q1 bitmask of all IRQ to be handled, may be more than one IRQ
# q2 q3 unused, can be use as temp storage register
# q Without the q-registers, the irq return address will be stored in x3 (gp) and the IRQ bitmask in x4 (tp),
# io.interrupt(0) := intTxError
# io.interrupt(1) := intRxError
# io.interrupt(2) := intRxStart
# io.interrupt(3) := intRxEnd
or sp, sp, x4
picorv32_retirq_insn()