更新软件代码
This commit is contained in:
@@ -9,23 +9,16 @@
|
||||
|
||||
|
||||
_prog_start:
|
||||
li sp, 0
|
||||
picorv32_maskirq_insn(zero, zero)
|
||||
li sp, 0x40001000
|
||||
|
||||
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
|
||||
@@ -33,15 +26,5 @@ trap_entry:
|
||||
# io.interrupt(3) := intRxEnd
|
||||
|
||||
|
||||
or sp, sp, x4
|
||||
|
||||
andi x4, x4, 0x2
|
||||
beqz x4, 1f
|
||||
li x4, 0
|
||||
sw x3, 0x400(x0)
|
||||
|
||||
1:
|
||||
picorv32_retirq_insn()
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user