mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-11-01 06:58:22 +00:00
scheduler: make timer request start on sched_init rather than sched_runinit
This commit is contained in:
@@ -418,6 +418,9 @@ void sched_init(){
|
|||||||
timer_req* req = &arch_getcls()->schedreq;
|
timer_req* req = &arch_getcls()->schedreq;
|
||||||
|
|
||||||
req->func = sched_timerhook;
|
req->func = sched_timerhook;
|
||||||
|
|
||||||
|
timer_add(&arch_getcls()->schedreq, THREAD_QUANTUM, true);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void sched_runinit(){
|
void sched_runinit(){
|
||||||
@@ -500,8 +503,6 @@ void sched_runinit(){
|
|||||||
fd_release(stderrfd);
|
fd_release(stderrfd);
|
||||||
|
|
||||||
proc->umask = 022;
|
proc->umask = 022;
|
||||||
|
|
||||||
timer_add(&arch_getcls()->schedreq, THREAD_QUANTUM, true);
|
|
||||||
|
|
||||||
switch_thread(thread);
|
switch_thread(thread);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user