diff options
author | Benji Dial <benji6283@gmail.com> | 2020-09-13 19:51:09 -0400 |
---|---|---|
committer | Benji Dial <benji6283@gmail.com> | 2020-09-13 19:51:09 -0400 |
commit | 143156f63e2448733f1a35a74e629fe0ae9bb567 (patch) | |
tree | bcf70a6940038986da2cfb2d6ed380ed8ebb91de /src/kernel/task.h | |
parent | 54101cf327b7def90636babbadbb66ce697298ee (diff) | |
download | portland-os-143156f63e2448733f1a35a74e629fe0ae9bb567.tar.gz |
have command shell block while commands are running
Diffstat (limited to 'src/kernel/task.h')
-rw-r--r-- | src/kernel/task.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/kernel/task.h b/src/kernel/task.h index 0fa9688..50be93a 100644 --- a/src/kernel/task.h +++ b/src/kernel/task.h @@ -6,6 +6,11 @@ #define TASK_NAME_LEN 15 +enum wait_mode { + NONE, + PROCESS_END, +}; + struct task_state { uint32_t ret_addr; void *page_directory; @@ -18,6 +23,9 @@ struct task_state { uint32_t ebp; uint32_t esp; + enum wait_mode wait_mode; + uint32_t wait_arg; + char name[TASK_NAME_LEN + 1]; } __attribute__ ((packed)); @@ -25,7 +33,7 @@ extern struct task_state *active_task; void init_tasks(); -void new_task(struct task_state state); +uint32_t new_task(struct task_state state); void advance_active_task(); void delete_task(struct task_state *state); |