diff options
author | Anton Kling <anton@kling.gg> | 2024-04-26 19:06:46 +0200 |
---|---|---|
committer | Anton Kling <anton@kling.gg> | 2024-04-26 19:06:46 +0200 |
commit | 7ab3153f92f38223157c4c1f4af1c30e33c94a76 (patch) | |
tree | 301f950cd6dc8fde244e9b5c1201ec01d964347b /kernel/fs/ext2.c | |
parent | 2e2805c88789c148cce0118d3a4ff0212458bb86 (diff) |
Kernel/VFS: Change polling from variables to functions
Instead of having to store state in variables functions are called to
check the object directly.
Diffstat (limited to 'kernel/fs/ext2.c')
-rw-r--r-- | kernel/fs/ext2.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/fs/ext2.c b/kernel/fs/ext2.c index c3fbd73..db947c0 100644 --- a/kernel/fs/ext2.c +++ b/kernel/fs/ext2.c @@ -604,7 +604,7 @@ vfs_inode_t *ext2_open(const char *path) { break; } - return vfs_create_inode(inode_num, type, 1 /*has_data*/, 1 /*can_write*/, + return vfs_create_inode(inode_num, type, NULL, NULL, 1 /*is_open*/, NULL /*internal_object*/, file_size, ext2_open, ext2_create_file, ext2_read, ext2_write, ext2_close, ext2_create_directory, @@ -805,7 +805,7 @@ vfs_inode_t *ext2_mount(void) { return NULL; } int fd = vfs_open("/dev/sda", O_RDWR, 0); - if(0 > fd) { + if (0 > fd) { kfree(cache); return NULL; } |