Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi
[linux-2.6-microblaze.git] / fs / ocfs2 / refcounttree.c
index 3b397fa..c19a463 100644 (file)
@@ -978,7 +978,7 @@ static int ocfs2_get_refcount_cpos_end(struct ocfs2_caching_info *ci,
                return 0;
        }
 
-       if (!eb || (eb && !eb->h_next_leaf_blk)) {
+       if (!eb || !eb->h_next_leaf_blk) {
                /*
                 * We are the last extent rec, so any high cpos should
                 * be stored in this leaf refcount block.
@@ -4346,7 +4346,7 @@ static inline int ocfs2_may_create(struct inode *dir, struct dentry *child)
                return -EEXIST;
        if (IS_DEADDIR(dir))
                return -ENOENT;
-       return inode_permission(dir, MAY_WRITE | MAY_EXEC);
+       return inode_permission(&init_user_ns, dir, MAY_WRITE | MAY_EXEC);
 }
 
 /**
@@ -4400,7 +4400,7 @@ static int ocfs2_vfs_reflink(struct dentry *old_dentry, struct inode *dir,
         * file.
         */
        if (!preserve) {
-               error = inode_permission(inode, MAY_READ);
+               error = inode_permission(&init_user_ns, inode, MAY_READ);
                if (error)
                        return error;
        }