os/kernel/cpu/tasking.h

20 lines
591 B
C
Raw Normal View History

#ifndef CPU_TASKING_H
#define CPU_TASKING_H
2019-02-25 15:42:23 -06:00
2019-02-11 09:30:28 -06:00
#include "i386/tasking.h"
2019-05-11 10:11:28 -05:00
#include "i386/isr.h"
2020-07-12 14:28:58 -05:00
#include <sys/types.h>
2019-02-11 09:30:28 -06:00
void tasking_init();
2020-07-12 16:29:57 -05:00
void tasking_yield(pid_t pid); //set pid to 0 for normal scheduling
Task* tasking_createTask(void* eip);
2019-06-29 09:04:34 -05:00
Task* tasking_createTaskCr3KmodeParam(void* eip,void* cr3,char kmode,char param1_exists,uint32_t param1_arg,char param2_exists,uint32_t param2_arg);
2019-02-25 15:42:23 -06:00
char isPrivleged(uint32_t pid);
uint32_t getPID();
void tasking_exit(uint8_t code);
2020-07-12 14:28:58 -05:00
void tasking_block(TaskState newstate);
void tasking_unblock(pid_t pid);
int* tasking_get_errno_address();
2019-02-11 09:30:28 -06:00
#endif