summaryrefslogtreecommitdiff
path: root/src/kernel/proc.h
diff options
context:
space:
mode:
authordzwdz2021-10-09 11:53:38 +0000
committerdzwdz2021-10-09 11:53:38 +0000
commitd9463f6e977ce686ac7a55f22b0b25b0ce67b025 (patch)
tree768fbb673945dba63dc8c5e02f8a4238da4148d7 /src/kernel/proc.h
parentfaed927869451cf4070abba91b5a9cf9e32c9a6c (diff)
parentacf41ff6fee44dd24f9383d96fecd992dcb072e2 (diff)
Merge branch 'main' of github.com:dzwdz/camellia
Diffstat (limited to 'src/kernel/proc.h')
-rw-r--r--src/kernel/proc.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/kernel/proc.h b/src/kernel/proc.h
index 82bb59a..7c338bb 100644
--- a/src/kernel/proc.h
+++ b/src/kernel/proc.h
@@ -26,10 +26,7 @@ struct process {
// saved value, meaning depends on .state
union {
- struct { // PS_DEAD, PS_WAITS4CHILDDEATH
- char __user *buf;
- size_t len;
- } death_msg;
+ int death_msg; // PS_DEAD
struct vfs_request pending_req; // PS_WAITS4FS
struct {
char __user *buf;
@@ -56,6 +53,8 @@ _Noreturn void process_switch_any(void); // switches to any running process
struct process *process_find(enum process_state);
handle_t process_find_handle(struct process *proc); // finds the first free handle
+void process_kill(struct process *proc, int ret);
+
/** Tries to transistion from PS_DEAD to PS_DEADER.
* @return a nonnegative length of the quit message if successful, a negative val otherwise*/
int process_try2collect(struct process *dead);