scheduler: getcwd, getroot, and initialise process cwd and root to vfsroot

This commit is contained in:
Matheus
2023-05-09 23:25:56 -03:00
parent 4cfb83f4fe
commit cfdab9598d
2 changed files with 38 additions and 0 deletions
+4
View File
@@ -50,6 +50,7 @@ typedef struct proc_t {
int flags;
vnode_t *cwd;
vnode_t *root;
spinlock_t nodeslock;
} proc_t;
#include <arch/cpu.h>
@@ -64,6 +65,9 @@ void sched_preparesleep(bool interruptible);
void sched_wakeup(thread_t *thread, int reason);
int sched_sleep();
proc_t *sched_newproc();
vnode_t *sched_getcwd();
vnode_t *sched_getroot();
thread_t *sched_newthread(void *ip, size_t kstacksize, int priority, proc_t *proc, void *ustack);
#endif