git://scm.lunaixsky.com
/
lunaix-os.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refactor: separate syscall interfaces from kernel space, into posix compliant structure.
[lunaix-os.git]
/
lunaix-os
/
kernel
/
fs
/
vfs.c
diff --git
a/lunaix-os/kernel/fs/vfs.c
b/lunaix-os/kernel/fs/vfs.c
index cbe3c39ab507a8021d453b01ab38f07803858bdb..e436eba969c1fea7e88a863adf9e518e579b7514 100644
(file)
--- a/
lunaix-os/kernel/fs/vfs.c
+++ b/
lunaix-os/kernel/fs/vfs.c
@@
-44,7
+44,6
@@
*/
#include <klibc/string.h>
*/
#include <klibc/string.h>
-#include <lunaix/dirent.h>
#include <lunaix/foptions.h>
#include <lunaix/fs.h>
#include <lunaix/mm/cake.h>
#include <lunaix/foptions.h>
#include <lunaix/fs.h>
#include <lunaix/mm/cake.h>
@@
-57,6
+56,8
@@
#include <lunaix/fs/twifs.h>
#include <lunaix/fs/twifs.h>
+#include <usr/sys/dirent_defs.h>
+
static struct cake_pile* dnode_pile;
static struct cake_pile* inode_pile;
static struct cake_pile* file_pile;
static struct cake_pile* dnode_pile;
static struct cake_pile* inode_pile;
static struct cake_pile* file_pile;
@@
-625,13
+626,13
@@
__vfs_readdir_callback(struct dir_context* dctx,
const int len,
const int dtype)
{
const int len,
const int dtype)
{
- struct
dirent* dent = (struct
dirent*)dctx->cb_data;
+ struct
lx_dirent* dent = (struct lx_
dirent*)dctx->cb_data;
strncpy(dent->d_name, name, DIRENT_NAME_MAX_LEN);
dent->d_nlen = len;
dent->d_type = dtype;
}
strncpy(dent->d_name, name, DIRENT_NAME_MAX_LEN);
dent->d_nlen = len;
dent->d_type = dtype;
}
-__DEFINE_LXSYSCALL2(int, sys_readdir, int, fd, struct dirent*, dent)
+__DEFINE_LXSYSCALL2(int, sys_readdir, int, fd, struct
lx_
dirent*, dent)
{
struct v_fd* fd_s;
int errno;
{
struct v_fd* fd_s;
int errno;