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
release the dnode lock after EACCESS in path walk
[lunaix-os.git]
/
lunaix-os
/
kernel
/
fs
/
twifs
/
twifs.c
diff --git
a/lunaix-os/kernel/fs/twifs/twifs.c
b/lunaix-os/kernel/fs/twifs/twifs.c
index 8f4ed8d05becfd6dcc290914cdae45af5bf6112b..9d474958bbe10763fc81c4b5d9a599a936ee7dbd 100644
(file)
--- a/
lunaix-os/kernel/fs/twifs/twifs.c
+++ b/
lunaix-os/kernel/fs/twifs/twifs.c
@@
-18,7
+18,7
@@
#include <lunaix/mm/valloc.h>
#include <lunaix/spike.h>
#include <lunaix/mm/valloc.h>
#include <lunaix/spike.h>
-#include <
sys/m
m/pagetable.h>
+#include <
as
m/pagetable.h>
static struct twifs_node* fs_root;
static struct twifs_node* fs_root;
@@
-58,6
+58,13
@@
__twifs_init_inode(struct v_superblock* vsb, struct v_inode* inode)
{
inode->ops = (struct v_inode_ops*)&twifs_inode_ops;
inode->default_fops = (struct v_file_ops*)&twifs_file_ops;
{
inode->ops = (struct v_inode_ops*)&twifs_inode_ops;
inode->default_fops = (struct v_file_ops*)&twifs_file_ops;
+
+
+ // we set default access right to be 0660.
+ // TODO need a way to allow this to be changed
+
+ fsapi_inode_setaccess(inode, FSACL_DEFAULT);
+ fsapi_inode_setowner(inode, 0, 0);
}
int
}
int