sched: implement various ways to end tasks and threads

This commit is contained in:
2026-03-18 21:07:43 +00:00
parent e03b2e07d0
commit 4551e7b2e6
12 changed files with 148 additions and 17 deletions

View File

@@ -1,10 +1,12 @@
#include <kernel/printk.h>
#include <kernel/sched.h>
#include <kernel/task.h>
#include <kernel/thread.h>
kern_status_t sys_kern_log(const char *s)
{
struct task *task = current_task();
printk("%s[%d]: %s", task->t_name, task->t_id, s);
struct thread *thread = current_thread();
printk("%s[%d.%d]: %s", task->t_name, task->t_id, thread->tr_id, s);
return KERN_OK;
}