summaryrefslogtreecommitdiffstats
path: root/tsk
diff options
context:
space:
mode:
Diffstat (limited to 'tsk')
-rw-r--r--tsk/tasking.h14
-rw-r--r--tsk/thread.c4
-rw-r--r--tsk/thread.d1
3 files changed, 10 insertions, 9 deletions
diff --git a/tsk/tasking.h b/tsk/tasking.h
index d217171..b322682 100644
--- a/tsk/tasking.h
+++ b/tsk/tasking.h
@@ -6,20 +6,22 @@
typedef size_t tid_t;
-struct Thread
+struct Task
{
- struct Thread *next;
+ struct Task *next;
tid_t id;
uintptr_t kbp;
size_t perm;
};
-extern struct Thread *thread_current;
+extern struct Task *task_current;
void tasking_setup(void);
-struct Thread *thread_new(struct Thread *parent);
-struct Thread *thread_get(tid_t id);
-void thread_perm_release(struct Thread *thread, size_t mask);
+struct Task *task_new(struct Task *parent);
+struct Task *task_get(tid_t id);
+
+void *task_get_pd(struct Task *task);
+void task_perm_release(struct Task *task, size_t mask);
#endif
diff --git a/tsk/thread.c b/tsk/thread.c
index 7fbafa6..cb4df25 100644
--- a/tsk/thread.c
+++ b/tsk/thread.c
@@ -1,7 +1,7 @@
#include "tasking.h"
void
-thread_perm_release(struct Thread *thread, size_t mask)
+task_perm_release(struct Task *task, size_t mask)
{
- thread->perm &= ~mask;
+ task->perm &= ~mask;
}
diff --git a/tsk/thread.d b/tsk/thread.d
deleted file mode 100644
index 1869275..0000000
--- a/tsk/thread.d
+++ /dev/null
@@ -1 +0,0 @@
-tsk/thread.o: tsk/thread.c tsk/tasking.h