.section .text .global __userspace_invoke .type __userspace_invoke, @function # __userspace_invoke(fn exec *entry) __userspace_invoke: csrw mepc, a0 csrw mie, zero csrr t0, mstatus li t1, (3 << 11) not t1, t1 and t0, t0, t1 li t1, (1 << 7) not t1, t1 and t0, t0, t1 li t1, (1 << 3) not t1, t1 and t0, t0, t1 csrw mstatus, t0 mret