提交 9501e4c4 编写于 作者: A Al Viro

switch coda

Coda ->d_revalidate() actually checks for root, ->d_delete() is irrelevant.
So we can use the same d_op for all coda dentries
Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
上级 b5c7d208
...@@ -61,7 +61,7 @@ static int coda_return_EIO(void) ...@@ -61,7 +61,7 @@ static int coda_return_EIO(void)
} }
#define CODA_EIO_ERROR ((void *) (coda_return_EIO)) #define CODA_EIO_ERROR ((void *) (coda_return_EIO))
static const struct dentry_operations coda_dentry_operations = const struct dentry_operations coda_dentry_operations =
{ {
.d_revalidate = coda_dentry_revalidate, .d_revalidate = coda_dentry_revalidate,
.d_delete = coda_dentry_delete, .d_delete = coda_dentry_delete,
...@@ -126,8 +126,6 @@ static struct dentry *coda_lookup(struct inode *dir, struct dentry *entry, struc ...@@ -126,8 +126,6 @@ static struct dentry *coda_lookup(struct inode *dir, struct dentry *entry, struc
return ERR_PTR(error); return ERR_PTR(error);
exit: exit:
d_set_d_op(entry, &coda_dentry_operations);
if (inode && (type & CODA_NOCACHE)) if (inode && (type & CODA_NOCACHE))
coda_flag_inode(inode, C_VATTR | C_PURGE); coda_flag_inode(inode, C_VATTR | C_PURGE);
......
...@@ -193,6 +193,7 @@ static int coda_fill_super(struct super_block *sb, void *data, int silent) ...@@ -193,6 +193,7 @@ static int coda_fill_super(struct super_block *sb, void *data, int silent)
sb->s_blocksize_bits = 12; sb->s_blocksize_bits = 12;
sb->s_magic = CODA_SUPER_MAGIC; sb->s_magic = CODA_SUPER_MAGIC;
sb->s_op = &coda_super_operations; sb->s_op = &coda_super_operations;
sb->s_d_op = &coda_dentry_operations;
sb->s_bdi = &vc->bdi; sb->s_bdi = &vc->bdi;
/* get root fid from Venus: this needs the root inode */ /* get root fid from Venus: this needs the root inode */
......
...@@ -27,6 +27,8 @@ extern const struct inode_operations coda_dir_inode_operations; ...@@ -27,6 +27,8 @@ extern const struct inode_operations coda_dir_inode_operations;
extern const struct inode_operations coda_file_inode_operations; extern const struct inode_operations coda_file_inode_operations;
extern const struct inode_operations coda_ioctl_inode_operations; extern const struct inode_operations coda_ioctl_inode_operations;
extern const struct dentry_operations coda_dentry_operations;
extern const struct address_space_operations coda_file_aops; extern const struct address_space_operations coda_file_aops;
extern const struct address_space_operations coda_symlink_aops; extern const struct address_space_operations coda_symlink_aops;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册