aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/kern_sched.c
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2024-04-10 16:37:58 -0400
committerIan Moffett <ian@osmora.org>2024-04-10 16:39:33 -0400
commitf9e1486c72f3e2b9fb002666bc9091ea691f8e42 (patch)
tree94c2e8e284a03927106669793133743fc42f351a /sys/kern/kern_sched.c
parente555b3c5901dc495e683529b663eab8ff0f36482 (diff)
kernel: signals: Add initial signal implementation
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/kern/kern_sched.c')
-rw-r--r--sys/kern/kern_sched.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/kern/kern_sched.c b/sys/kern/kern_sched.c
index afaf6a8..877c55d 100644
--- a/sys/kern/kern_sched.c
+++ b/sys/kern/kern_sched.c
@@ -38,6 +38,7 @@
#include <sys/panic.h>
#include <sys/machdep.h>
#include <sys/filedesc.h>
+#include <sys/signal.h>
#include <fs/initramfs.h>
#include <vm/dynalloc.h>
#include <vm/physseg.h>
@@ -353,6 +354,10 @@ sched_context_switch(struct trapframe *tf)
struct sched_state *state = &ci->sched_state;
struct proc *td, *next_td;
+ if (state->td != NULL) {
+ signal_handle(state->td);
+ }
+
/*
* If we have no threads, we should not
* preempt at all.