diff options
Diffstat (limited to 'kernel/syscalls.c')
| -rw-r--r-- | kernel/syscalls.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/kernel/syscalls.c b/kernel/syscalls.c index 5205bf1..8b5040a 100644 --- a/kernel/syscalls.c +++ b/kernel/syscalls.c @@ -16,6 +16,7 @@ #include "scheduler.h" #include "log.h" #include "timer.h" +#include "mount.h" static fd fds[MAX_FD]; static uint32_t next_fd=0; @@ -155,9 +156,7 @@ int syscall_read(int file, char *buf, int len) //TODO: replace with dirent! int syscall_readdir(const char *name,fs_dirent *dirs,int *pos) { - uint32_t inode = ext2_filename_to_inode(VMEM_EXT2_RAMIMAGE,name); - if(inode==0)return 0; - return ext2_read_dir(VMEM_EXT2_RAMIMAGE, inode, dirs, pos); + return mount_read_dir(name, dirs, pos); } // for non blocking io? @@ -330,7 +329,7 @@ int syscall_open(char *name, int flags, int mode) } else { - fds[next_fd]=fd_from_path(name); + fds[next_fd]=mount_file_open(name); if(*(uint32_t *)fds[next_fd].data==0)return -1; } |
