From 3701a82d3f2d27b8097ce56c0655df7efc0f0153 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Thu, 3 Jul 2025 18:03:44 -0400 Subject: kernel: proc: Add getpid() and getppid() Signed-off-by: Ian Moffett --- sys/include/sys/proc.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'sys/include') diff --git a/sys/include/sys/proc.h b/sys/include/sys/proc.h index 241d990..7aa04b2 100644 --- a/sys/include/sys/proc.h +++ b/sys/include/sys/proc.h @@ -90,6 +90,12 @@ struct proc *this_td(void); struct proc *get_child(struct proc *cur, pid_t pid); void proc_reap(struct proc *td); +pid_t getpid(void); +pid_t getppid(void); + +scret_t sys_getpid(struct syscall_args *scargs); +scret_t sys_getppid(struct syscall_args *scargs); + int md_spawn(struct proc *p, struct proc *parent, uintptr_t ip); scret_t sys_spawn(struct syscall_args *scargs); -- cgit v1.2.3