Небольшое исправление инициализации потока

This commit is contained in:
Aren Elchinyan 2024-01-23 21:00:04 +03:00
parent 29bfc8faba
commit c875299b3d
2 changed files with 4 additions and 2 deletions

View File

@ -1,3 +1,3 @@
#define VERSION_MAJOR 0
#define VERSION_MINOR 1
#define VERSION_BUILD 984
#define VERSION_BUILD 986

View File

@ -65,6 +65,7 @@ uint64_t task_new_thread(void (*func)(void *)) {
new_task->rsp = (uint64_t)new_task->stack + sizeof(uint64_t) * stack_top;
new_task->cpu_time = 500;
new_task->cpu_time_expired = new_task->cpu_time;
new_task->id = next_thread_id++;
new_task->cr3 = cr3;
@ -105,7 +106,8 @@ void task_init( ) {
kernel_task->id = next_thread_id++;
kernel_task->rsp = rsp;
kernel_task->cr3 = cr3;
kernel_task->cpu_time = 1000;
kernel_task->cpu_time = 100;
kernel_task->cpu_time_expired = kernel_task->cpu_time;
current_task = kernel_task;