ceph: LOOKUP_OPEN is set only when it's the last component
[pandora-kernel.git] / fs / ceph / dir.c
index ef8f08c..b6d436f 100644 (file)
@@ -566,7 +566,6 @@ static struct dentry *ceph_lookup(struct inode *dir, struct dentry *dentry,
        /* open (but not create!) intent? */
        if (nd &&
            (nd->flags & LOOKUP_OPEN) &&
        /* open (but not create!) intent? */
        if (nd &&
            (nd->flags & LOOKUP_OPEN) &&
-           (nd->flags & LOOKUP_CONTINUE) == 0 && /* only open last component */
            !(nd->intent.open.flags & O_CREAT)) {
                int mode = nd->intent.open.create_mode & ~current->fs->umask;
                return ceph_lookup_open(dir, dentry, nd, mode, 1);
            !(nd->intent.open.flags & O_CREAT)) {
                int mode = nd->intent.open.create_mode & ~current->fs->umask;
                return ceph_lookup_open(dir, dentry, nd, mode, 1);