]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - fs/cifs/fcntl.c
Pull 5165 into release branch
[karo-tx-linux.git] / fs / cifs / fcntl.c
index 9d24c40f1967ad6ec5aad6e79d88db69deda93d2..a7a47bb36bf30888ea87bd62592ed732bba05d25 100644 (file)
@@ -78,6 +78,10 @@ int cifs_dir_notify(struct file * file, unsigned long arg)
        __u32 filter = FILE_NOTIFY_CHANGE_NAME | FILE_NOTIFY_CHANGE_ATTRIBUTES;
        __u16 netfid;
 
+
+       if(experimEnabled == 0)
+               return 0;
+
        xid = GetXid();
        cifs_sb = CIFS_SB(file->f_dentry->d_sb);
        pTcon = cifs_sb->tcon;
@@ -92,15 +96,18 @@ int cifs_dir_notify(struct file * file, unsigned long arg)
                cERROR(1,("cifs dir notify on file %s with arg 0x%lx",full_path,arg)); /* BB removeme BB */
                rc = CIFSSMBOpen(xid, pTcon, full_path, FILE_OPEN, 
                        GENERIC_READ | SYNCHRONIZE, 0 /* create options */,
-                       &netfid, &oplock,NULL, cifs_sb->local_nls);
+                       &netfid, &oplock,NULL, cifs_sb->local_nls,
+                       cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SPECIAL_CHR);
                /* BB fixme - add this handle to a notify handle list */
                if(rc) {
                        cERROR(1,("Could not open directory for notify"));  /* BB remove BB */
                } else {
                        filter = convert_to_cifs_notify_flags(arg);
                        if(filter != 0) {
-                               rc = CIFSSMBNotify(xid, pTcon, 0 /* no subdirs */, netfid, 
-                                       filter, cifs_sb->local_nls);
+                               rc = CIFSSMBNotify(xid, pTcon, 
+                                       0 /* no subdirs */, netfid,
+                                       filter, file, arg & DN_MULTISHOT,
+                                       cifs_sb->local_nls);
                        } else {
                                rc = -EINVAL;
                        }
@@ -108,7 +115,7 @@ int cifs_dir_notify(struct file * file, unsigned long arg)
                        it would close automatically but may be a way
                        to do it easily when inode freed or when
                        notify info is cleared/changed */
-            cERROR(1,("notify rc %d",rc));
+                       cFYI(1,("notify rc %d",rc));
                }
        }