Commit 450b21d1 authored by Petr Vandrovec's avatar Petr Vandrovec

Do not call ncp_lookup_validate on mountpoint.

parent 7fde4915
...@@ -73,7 +73,7 @@ static int ncp_hash_dentry(struct dentry *, struct qstr *); ...@@ -73,7 +73,7 @@ static int ncp_hash_dentry(struct dentry *, struct qstr *);
static int ncp_compare_dentry (struct dentry *, struct qstr *, struct qstr *); static int ncp_compare_dentry (struct dentry *, struct qstr *, struct qstr *);
static int ncp_delete_dentry(struct dentry *); static int ncp_delete_dentry(struct dentry *);
struct dentry_operations ncp_dentry_operations = static struct dentry_operations ncp_dentry_operations =
{ {
d_revalidate: ncp_lookup_validate, d_revalidate: ncp_lookup_validate,
d_hash: ncp_hash_dentry, d_hash: ncp_hash_dentry,
...@@ -81,6 +81,13 @@ struct dentry_operations ncp_dentry_operations = ...@@ -81,6 +81,13 @@ struct dentry_operations ncp_dentry_operations =
d_delete: ncp_delete_dentry, d_delete: ncp_delete_dentry,
}; };
struct dentry_operations ncp_root_dentry_operations =
{
d_hash: ncp_hash_dentry,
d_compare: ncp_compare_dentry,
d_delete: ncp_delete_dentry,
};
/* /*
* Note: leave the hash unchanged if the directory * Note: leave the hash unchanged if the directory
......
...@@ -90,7 +90,7 @@ static struct super_operations ncp_sops = ...@@ -90,7 +90,7 @@ static struct super_operations ncp_sops =
statfs: ncp_statfs, statfs: ncp_statfs,
}; };
extern struct dentry_operations ncp_dentry_operations; extern struct dentry_operations ncp_root_dentry_operations;
#ifdef CONFIG_NCPFS_EXTRAS #ifdef CONFIG_NCPFS_EXTRAS
extern struct address_space_operations ncp_symlink_aops; extern struct address_space_operations ncp_symlink_aops;
extern int ncp_symlink(struct inode*, struct dentry*, const char*); extern int ncp_symlink(struct inode*, struct dentry*, const char*);
...@@ -502,7 +502,7 @@ static int ncp_fill_super(struct super_block *sb, void *raw_data, int silent) ...@@ -502,7 +502,7 @@ static int ncp_fill_super(struct super_block *sb, void *raw_data, int silent)
sb->s_root = d_alloc_root(root_inode); sb->s_root = d_alloc_root(root_inode);
if (!sb->s_root) if (!sb->s_root)
goto out_no_root; goto out_no_root;
sb->s_root->d_op = &ncp_dentry_operations; sb->s_root->d_op = &ncp_root_dentry_operations;
return 0; return 0;
out_no_root: out_no_root:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment