summaryrefslogtreecommitdiff
path: root/Kernel/init.cpp
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-11-09 22:18:16 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-11-09 22:42:19 +0100
commitfbeb1ab15b8e1730a42eb43b4b211d17fe2bbb01 (patch)
treeb37ef083678e297f23684593c964bc1822041d61 /Kernel/init.cpp
parent874ebbe4a54e1a26ab0fa074575ef693b52f8eda (diff)
downloadserenity-fbeb1ab15b8e1730a42eb43b4b211d17fe2bbb01.zip
Kernel: Use a lookup table for syscalls
Instead of the big ugly switch statement, build a lookup table using the syscall enumeration macro. This greatly simplifies the syscall implementation. :^)
Diffstat (limited to 'Kernel/init.cpp')
-rw-r--r--Kernel/init.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/init.cpp b/Kernel/init.cpp
index 16f03a59e8..ee00438879 100644
--- a/Kernel/init.cpp
+++ b/Kernel/init.cpp
@@ -307,7 +307,7 @@ extern "C" [[noreturn]] void init(u32 physical_address_for_kernel_page_tables)
Process::create_kernel_process("init_stage2", init_stage2);
Process::create_kernel_process("syncd", [] {
for (;;) {
- Syscall::sync();
+ VFS::the().sync();
current->sleep(1 * TICKS_PER_SECOND);
}
});