summaryrefslogtreecommitdiff
path: root/kernel/init/kernel.c
diff options
context:
space:
mode:
authorAnton Kling <anton@kling.gg>2023-11-13 19:20:36 +0100
committerAnton Kling <anton@kling.gg>2023-11-13 19:23:58 +0100
commit1de1e8d02f392ed8bb061705d7717351bf3023bd (patch)
tree2f44b4e79d62225b27a8823bdfd9634ba5cb6a4e /kernel/init/kernel.c
parent1966047921e2958469f9faac1bd1f56d1fc5587a (diff)
Kernel: Add support for AHCI and make use of it with the current filesystem.
It will now also create a corresponding /dev/sd* device for each detected SATA drive. The filesystem still writes using the ATA driver. This should be fixed soon.
Diffstat (limited to 'kernel/init/kernel.c')
-rw-r--r--kernel/init/kernel.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/kernel/init/kernel.c b/kernel/init/kernel.c
index e9c8ea1..24da680 100644
--- a/kernel/init/kernel.c
+++ b/kernel/init/kernel.c
@@ -23,7 +23,6 @@
#include <sched/scheduler.h>
#include <stdbool.h>
#include <stddef.h>
-#include <typedefs.h>
#include <stdio.h>
#include <string.h>
#include <typedefs.h>
@@ -82,8 +81,10 @@ void kernel_main(u32 kernel_end, unsigned long magic, unsigned long addr,
install_keyboard();
klog("PS2 Keyboard driver installed", LOG_SUCCESS);
- vfs_mount("/", ext2_mount());
vfs_mount("/dev", devfs_mount());
+ ahci_init();
+ vfs_mount("/", ext2_mount());
+
add_stdout();
add_serial();
add_random_devices();