diff options
| author | manuel <manuel@mausz.at> | 2012-06-19 23:31:28 +0200 |
|---|---|---|
| committer | manuel <manuel@mausz.at> | 2012-06-19 23:31:28 +0200 |
| commit | abd273ce0a9ae9267f8b0a144ea9b56d8912f9b5 (patch) | |
| tree | 15bf5622a6bf7665dfb53a3f557dfaa246f108aa /userprog/process.h | |
| parent | e88a8c4c379d721e9901752d440a05295087da11 (diff) | |
| download | progos-abd273ce0a9ae9267f8b0a144ea9b56d8912f9b5.tar.gz progos-abd273ce0a9ae9267f8b0a144ea9b56d8912f9b5.tar.bz2 progos-abd273ce0a9ae9267f8b0a144ea9b56d8912f9b5.zip | |
add dynamic stack growing
Diffstat (limited to 'userprog/process.h')
| -rw-r--r-- | userprog/process.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/userprog/process.h b/userprog/process.h index b7bca5d..ccb94cb 100644 --- a/userprog/process.h +++ b/userprog/process.h | |||
| @@ -3,6 +3,8 @@ | |||
| 3 | 3 | ||
| 4 | #include "threads/thread.h" | 4 | #include "threads/thread.h" |
| 5 | 5 | ||
| 6 | #define STACK_SIZE (1 << 23) /* 8MB maxiumum stack size */ | ||
| 7 | |||
| 6 | /* In the current implementation, the capacity is fixed to 1024 (PGSIZE/4) */ | 8 | /* In the current implementation, the capacity is fixed to 1024 (PGSIZE/4) */ |
| 7 | struct fd_table { | 9 | struct fd_table { |
| 8 | struct file** fds; | 10 | struct file** fds; |
| @@ -37,6 +39,7 @@ tid_t process_execute (const char *file_name); | |||
| 37 | int process_wait (tid_t); | 39 | int process_wait (tid_t); |
| 38 | void process_exit (void); | 40 | void process_exit (void); |
| 39 | void process_activate (void); | 41 | void process_activate (void); |
| 42 | bool process_grow_stack (void *upage); | ||
| 40 | bool process_install_page (void *upage, void *kpage, bool writable); | 43 | bool process_install_page (void *upage, void *kpage, bool writable); |
| 41 | 44 | ||
| 42 | int process_open_file(const char* fname); | 45 | int process_open_file(const char* fname); |
