GFS2: Check for glock already held in gfs2_getxattr
[deliverable/linux.git] / fs / gfs2 / inode.c
index a01b8fd3a1c16c7b3363d5e6fac5ec54e5390119..64915eeae5a7112f59256185a00a1cc9f3b2a193 100644 (file)
@@ -1750,6 +1750,10 @@ static ssize_t gfs2_getxattr(struct dentry *dentry, const char *name,
        struct gfs2_holder gh;
        int ret;
 
+       /* For selinux during lookup */
+       if (gfs2_glock_is_locked_by_me(ip->i_gl))
+               return generic_getxattr(dentry, name, data, size);
+
        gfs2_holder_init(ip->i_gl, LM_ST_SHARED, LM_FLAG_ANY, &gh);
        ret = gfs2_glock_nq(&gh);
        if (ret == 0) {
This page took 0.027827 seconds and 5 git commands to generate.