Always lookup priv_root on reiserfs mount and keep it
... even if it's a negative dentry. That way we can set ->d_op on root before anyone could race with us. Simplify d_compare(), while we are at it. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
@@ -1842,7 +1842,8 @@ static int reiserfs_fill_super(struct super_block *s, void *data, int silent)
|
||||
goto error;
|
||||
}
|
||||
|
||||
if ((errval = reiserfs_xattr_init(s, s->s_flags))) {
|
||||
if ((errval = reiserfs_lookup_privroot(s)) ||
|
||||
(errval = reiserfs_xattr_init(s, s->s_flags))) {
|
||||
dput(s->s_root);
|
||||
s->s_root = NULL;
|
||||
goto error;
|
||||
@@ -1855,7 +1856,8 @@ static int reiserfs_fill_super(struct super_block *s, void *data, int silent)
|
||||
reiserfs_info(s, "using 3.5.x disk format\n");
|
||||
}
|
||||
|
||||
if ((errval = reiserfs_xattr_init(s, s->s_flags))) {
|
||||
if ((errval = reiserfs_lookup_privroot(s)) ||
|
||||
(errval = reiserfs_xattr_init(s, s->s_flags))) {
|
||||
dput(s->s_root);
|
||||
s->s_root = NULL;
|
||||
goto error;
|
||||
|
Reference in New Issue
Block a user