]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - fs/cifs/dir.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6
[mv-sheeva.git] / fs / cifs / dir.c
index c1bd0306d6c6ec553452b8e4b3352cfd014a49c2..ae576fbb5142e508010d53d1506b72fd954575e7 100644 (file)
@@ -174,7 +174,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode,
        if (oplockEnabled)
                oplock = REQ_OPLOCK;
 
-       if (nd && (nd->flags & LOOKUP_OPEN))
+       if (nd)
                oflags = nd->intent.open.file->f_flags;
        else
                oflags = O_RDONLY | O_CREAT;
@@ -209,7 +209,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode,
                   which should be rare for path not covered on files) */
        }
 
-       if (nd && (nd->flags & LOOKUP_OPEN)) {
+       if (nd) {
                /* if the file is going to stay open, then we
                   need to set the desired access properly */
                desiredAccess = 0;
@@ -323,7 +323,7 @@ cifs_create_set_dentry:
        else
                cFYI(1, "Create worked, get_inode_info failed rc = %d", rc);
 
-       if (newinode && nd && (nd->flags & LOOKUP_OPEN)) {
+       if (newinode && nd) {
                struct cifsFileInfo *pfile_info;
                struct file *filp;
 
@@ -563,7 +563,7 @@ cifs_lookup(struct inode *parent_dir_inode, struct dentry *direntry,
         * reduction in network traffic in the other paths.
         */
        if (pTcon->unix_ext) {
-               if (nd && !(nd->flags & (LOOKUP_PARENT | LOOKUP_DIRECTORY)) &&
+               if (nd && !(nd->flags & LOOKUP_DIRECTORY) &&
                     (nd->flags & LOOKUP_OPEN) && !pTcon->broken_posix_open &&
                     (nd->intent.open.file->f_flags & O_CREAT)) {
                        rc = cifs_posix_open(full_path, &newInode,
@@ -658,10 +658,8 @@ cifs_d_revalidate(struct dentry *direntry, struct nameidata *nd)
         * case sensitive name which is specified by user if this is
         * for creation.
         */
-       if (!(nd->flags & (LOOKUP_CONTINUE | LOOKUP_PARENT))) {
-               if (nd->flags & (LOOKUP_CREATE | LOOKUP_RENAME_TARGET))
-                       return 0;
-       }
+       if (nd->flags & (LOOKUP_CREATE | LOOKUP_RENAME_TARGET))
+               return 0;
 
        if (time_after(jiffies, direntry->d_time + HZ) || !lookupCacheEnabled)
                return 0;