]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/blobdiff - fs/gfs2/ops_fstype.c
[GFS2] Set d_ops for root inode
[mirror_ubuntu-jammy-kernel.git] / fs / gfs2 / ops_fstype.c
index 70745f3561a6bd66e1cc6fcd0f7ac43ac50c190b..f252723b37da1a21137e2a0cd7c2fb1d76bb4d5b 100644 (file)
@@ -40,6 +40,8 @@
 #define DO 0
 #define UNDO 1
 
+extern struct dentry_operations gfs2_dops;
+
 static struct gfs2_sbd *init_sbd(struct super_block *sb)
 {
        struct gfs2_sbd *sdp;
@@ -223,7 +225,7 @@ static int init_locking(struct gfs2_sbd *sdp, struct gfs2_holder *mount_gh,
        error = gfs2_glock_nq_num(sdp,
                                  GFS2_LIVE_LOCK, &gfs2_nondisk_glops,
                                  LM_ST_SHARED,
-                                 LM_FLAG_NOEXP | GL_EXACT | GL_NEVER_RECURSE,
+                                 LM_FLAG_NOEXP | GL_EXACT,
                                  &sdp->sd_live_gh);
        if (error) {
                fs_err(sdp, "can't acquire live glock: %d\n", error);
@@ -357,6 +359,7 @@ static int init_sb(struct gfs2_sbd *sdp, int silent, int undo)
                error = -ENOMEM;
                iput(inode);
        }
+       sb->s_root->d_op = &gfs2_dops;
 out:
        gfs2_glock_dq_uninit(&sb_gh);
        return error;
@@ -638,7 +641,7 @@ static int init_per_node(struct gfs2_sbd *sdp, int undo)
 
        ip = sdp->sd_ir_inode->u.generic_ip;
        error = gfs2_glock_nq_init(ip->i_gl,
-                                  LM_ST_EXCLUSIVE, GL_NEVER_RECURSE,
+                                  LM_ST_EXCLUSIVE, 0,
                                   &sdp->sd_ir_gh);
        if (error) {
                fs_err(sdp, "can't lock local \"ir\" file: %d\n", error);
@@ -647,7 +650,7 @@ static int init_per_node(struct gfs2_sbd *sdp, int undo)
 
        ip = sdp->sd_sc_inode->u.generic_ip;
        error = gfs2_glock_nq_init(ip->i_gl,
-                                  LM_ST_EXCLUSIVE, GL_NEVER_RECURSE,
+                                  LM_ST_EXCLUSIVE, 0,
                                   &sdp->sd_sc_gh);
        if (error) {
                fs_err(sdp, "can't lock local \"sc\" file: %d\n", error);
@@ -656,7 +659,7 @@ static int init_per_node(struct gfs2_sbd *sdp, int undo)
 
        ip = sdp->sd_ut_inode->u.generic_ip;
        error = gfs2_glock_nq_init(ip->i_gl,
-                                  LM_ST_EXCLUSIVE, GL_NEVER_RECURSE,
+                                  LM_ST_EXCLUSIVE, 0,
                                   &sdp->sd_ut_gh);
        if (error) {
                fs_err(sdp, "can't lock local \"ut\" file: %d\n", error);
@@ -665,7 +668,7 @@ static int init_per_node(struct gfs2_sbd *sdp, int undo)
 
        ip = sdp->sd_qc_inode->u.generic_ip;
        error = gfs2_glock_nq_init(ip->i_gl,
-                                  LM_ST_EXCLUSIVE, GL_NEVER_RECURSE,
+                                  LM_ST_EXCLUSIVE, 0,
                                   &sdp->sd_qc_gh);
        if (error) {
                fs_err(sdp, "can't lock local \"qc\" file: %d\n", error);