aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/fs/vfs.c
diff options
context:
space:
mode:
authorMarvin Borner2020-05-02 18:17:35 +0200
committerMarvin Borner2020-05-02 18:17:35 +0200
commite8f1c287a63f0f71fe463f7271834538b45f8c05 (patch)
tree6eebab2d27e610c8eeb130ddfd6a7f858ece411a /src/kernel/fs/vfs.c
parentaa8a8811818331cf511681327e3ba95e456f0d33 (diff)
Some work in the vfs
Diffstat (limited to 'src/kernel/fs/vfs.c')
-rw-r--r--src/kernel/fs/vfs.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/kernel/fs/vfs.c b/src/kernel/fs/vfs.c
index fd44f30..2b4cda4 100644
--- a/src/kernel/fs/vfs.c
+++ b/src/kernel/fs/vfs.c
@@ -1,6 +1,7 @@
#include <stdint.h>
#include <stddef.h>
#include <kernel/fs/vfs.h>
+#include <kernel/fs/ext2.h>
#include <kernel/lib/stdlib.h>
struct fs_node *fs_root = NULL;
@@ -25,12 +26,16 @@ void fs_open(struct fs_node *node)
{
if (node->open != NULL)
node->open(node);
+ else // TODO: Better ext2 default open workaround
+ ext2_root->open(node);
}
void fs_close(struct fs_node *node)
{
if (node->close != NULL)
node->close(node);
+ else
+ ext2_root->open(node);
}
struct dirent *fs_read_dir(struct fs_node *node, uint32_t index)