summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/init/main.c1
-rw-r--r--src/init/syscalls.c1
-rw-r--r--src/init/tar.c1
-rw-r--r--src/init/types.h5
-rw-r--r--src/kernel/arch/generic.h2
-rw-r--r--src/kernel/arch/i386/registers.h2
-rw-r--r--src/kernel/handle.h2
-rw-r--r--src/kernel/mem/virt.h2
-rw-r--r--src/kernel/syscalls.c1
-rw-r--r--src/kernel/vfs/root.c1
-rw-r--r--src/shared/syscalls.h5
-rw-r--r--src/shared/types.h (renamed from src/kernel/types.h)2
12 files changed, 5 insertions, 20 deletions
diff --git a/src/init/main.c b/src/init/main.c
index 683d0ca..aef6410 100644
--- a/src/init/main.c
+++ b/src/init/main.c
@@ -1,5 +1,4 @@
#include <init/tar.h>
-#include <init/types.h>
#include <shared/flags.h>
#include <shared/syscalls.h>
#include <stdint.h>
diff --git a/src/init/syscalls.c b/src/init/syscalls.c
index 6e00895..549ff61 100644
--- a/src/init/syscalls.c
+++ b/src/init/syscalls.c
@@ -1,5 +1,4 @@
// this file could probably just get generated by a script
-#include <init/types.h>
#include <shared/syscalls.h>
_Noreturn void _syscall_exit(const char __user *msg, size_t len) {
diff --git a/src/init/tar.c b/src/init/tar.c
index 22e4785..24adfce 100644
--- a/src/init/tar.c
+++ b/src/init/tar.c
@@ -1,4 +1,3 @@
-#include <init/types.h>
#include <shared/syscalls.h>
#include <stdint.h>
diff --git a/src/init/types.h b/src/init/types.h
deleted file mode 100644
index 9c6d64b..0000000
--- a/src/init/types.h
+++ /dev/null
@@ -1,5 +0,0 @@
-#pragma once
-
-#define TYPES_INCLUDED
-
-#define __user
diff --git a/src/kernel/arch/generic.h b/src/kernel/arch/generic.h
index 0696a96..e5ececd 100644
--- a/src/kernel/arch/generic.h
+++ b/src/kernel/arch/generic.h
@@ -1,8 +1,8 @@
#pragma once
-#include <kernel/types.h>
#include <kernel/arch/i386/registers.h>
#include <kernel/arch/log.h>
+#include <shared/types.h>
#include <stdbool.h>
// i have no idea where else to put it
diff --git a/src/kernel/arch/i386/registers.h b/src/kernel/arch/i386/registers.h
index 5443b10..8bd090d 100644
--- a/src/kernel/arch/i386/registers.h
+++ b/src/kernel/arch/i386/registers.h
@@ -1,5 +1,5 @@
#pragma once
-#include <kernel/types.h>
+#include <shared/types.h>
#include <stdint.h>
struct registers {
diff --git a/src/kernel/handle.h b/src/kernel/handle.h
index 4ec8e57..917f738 100644
--- a/src/kernel/handle.h
+++ b/src/kernel/handle.h
@@ -1,6 +1,6 @@
#pragma once
-#include <kernel/types.h>
#include <kernel/vfs/mount.h>
+#include <shared/types.h>
#include <stddef.h>
#define HANDLE_MAX 16
diff --git a/src/kernel/mem/virt.h b/src/kernel/mem/virt.h
index 54454e9..3a42e9e 100644
--- a/src/kernel/mem/virt.h
+++ b/src/kernel/mem/virt.h
@@ -1,6 +1,6 @@
/* contains utilities for interacting with virtual memory */
#pragma once
-#include <kernel/types.h>
+#include <shared/types.h>
#include <stdbool.h>
#include <stddef.h>
diff --git a/src/kernel/syscalls.c b/src/kernel/syscalls.c
index a5c6f43..1bc9694 100644
--- a/src/kernel/syscalls.c
+++ b/src/kernel/syscalls.c
@@ -3,7 +3,6 @@
#include <kernel/mem/virt.h>
#include <kernel/panic.h>
#include <kernel/proc.h>
-#include <kernel/types.h>
#include <kernel/vfs/path.h>
#include <shared/flags.h>
#include <shared/syscalls.h>
diff --git a/src/kernel/vfs/root.c b/src/kernel/vfs/root.c
index feb718d..6fcfc08 100644
--- a/src/kernel/vfs/root.c
+++ b/src/kernel/vfs/root.c
@@ -1,7 +1,6 @@
#include <kernel/mem/virt.h>
#include <kernel/panic.h>
#include <kernel/proc.h>
-#include <kernel/types.h>
#include <kernel/util.h>
#include <kernel/vfs/root.h>
diff --git a/src/shared/syscalls.h b/src/shared/syscalls.h
index 36588b6..2c1648e 100644
--- a/src/shared/syscalls.h
+++ b/src/shared/syscalls.h
@@ -1,10 +1,7 @@
#pragma once
+#include <shared/types.h>
#include <stddef.h>
-#ifndef TYPES_INCLUDED
-# error "please include <kernel/types.h> or <init/types.h> before this file"
-#endif
-
typedef int handle_t;
enum {
diff --git a/src/kernel/types.h b/src/shared/types.h
index 44a0d46..5dd39ad 100644
--- a/src/kernel/types.h
+++ b/src/shared/types.h
@@ -1,8 +1,6 @@
#pragma once
#include <stdint.h>
-#define TYPES_INCLUDED
-
#ifdef __CHECKER__
# define __user __attribute__((noderef, address_space(__user)))
#else