4 #include <lunaix/mm/vmm.h>
5 #include <lunaix/process.h>
6 #include <lunaix/sched.h>
7 #include <lunaix/syslog.h>
9 #include <asm/x86_isrm.h>
14 update_thread_context(struct hart_state* state)
16 if (!current_thread) {
20 struct hart_state* parent = current_thread->hstate;
21 hart_push_state(parent, state);
22 current_thread->hstate = state;
25 state->depth = parent->depth + 1;
30 intr_handler(struct hart_state* state)
32 update_thread_context(state);
34 volatile struct exec_param* execp = state->execp;
35 if (execp->vector <= 255) {
36 isr_cb subscriber = isrm_get(execp->vector);
43 if (execp->vector > IV_BASE_END) {
44 isrm_notify_eoi(0, execp->vector);