aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/kernel.c
diff options
context:
space:
mode:
authorMarvin Borner2020-04-01 22:58:54 +0200
committerMarvin Borner2020-04-01 22:58:54 +0200
commitce13b28b90e8f7d8083658e083831c6528847099 (patch)
tree54882764e8bdad831c6a787b7c1d5d52d1ae4f48 /src/kernel/kernel.c
parentf79ada76d2e4056ff5a81b53998d6d2696523d0f (diff)
Static address linking approach for userspace
Kinda works but loading an statically linked binary into memory via kmalloc seems to create a crash which results in a bootloop.
Diffstat (limited to 'src/kernel/kernel.c')
-rw-r--r--src/kernel/kernel.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/kernel/kernel.c b/src/kernel/kernel.c
index e5cb666..e1822d8 100644
--- a/src/kernel/kernel.c
+++ b/src/kernel/kernel.c
@@ -57,14 +57,12 @@ void kernel_main(uint32_t initial_stack)
install_melvix();
#endif
- loader_init();
- elf_init();
- exec_start((uint8_t *)userspace);
+ load_elf((char *)userspace);
- // syscalls_install();
- // exec(userspace);
+ // syscalls_install();
+ // exec(userspace);
panic("This should NOT happen!");
// asm ("div %0" :: "r"(0)); // Exception testing x/0
-} \ No newline at end of file
+}