]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/nfs/file.c
[JFFS2] Use .unlocked_ioctl
[linux-2.6-omap-h63xx.git] / fs / nfs / file.c
index 10e8b807e7ff1de0991b6a1d4d11d79afe09816f..d84a3d8f32af395f8109b58dcdd232fc3d0ddaa3 100644 (file)
@@ -64,7 +64,11 @@ const struct file_operations nfs_file_operations = {
        .write          = do_sync_write,
        .aio_read       = nfs_file_read,
        .aio_write      = nfs_file_write,
+#ifdef CONFIG_MMU
        .mmap           = nfs_file_mmap,
+#else
+       .mmap           = generic_file_mmap,
+#endif
        .open           = nfs_file_open,
        .flush          = nfs_file_flush,
        .release        = nfs_file_release,
@@ -522,7 +526,7 @@ static int do_vfs_lock(struct file *file, struct file_lock *fl)
        if (res < 0)
                dprintk(KERN_WARNING "%s: VFS is out of sync with lock manager"
                        " - error %d!\n",
-                               __FUNCTION__, res);
+                               __func__, res);
        return res;
 }
 
@@ -566,17 +570,9 @@ static int do_setlk(struct file *filp, int cmd, struct file_lock *fl)
 
        lock_kernel();
        /* Use local locking if mounted with "-onolock" */
-       if (!(NFS_SERVER(inode)->flags & NFS_MOUNT_NONLM)) {
+       if (!(NFS_SERVER(inode)->flags & NFS_MOUNT_NONLM))
                status = NFS_PROTO(inode)->lock(filp, cmd, fl);
-               /* If we were signalled we still need to ensure that
-                * we clean up any state on the server. We therefore
-                * record the lock call as having succeeded in order to
-                * ensure that locks_remove_posix() cleans it out when
-                * the process exits.
-                */
-               if (status == -EINTR || status == -ERESTARTSYS)
-                       do_vfs_lock(filp, fl);
-       } else
+       else
                status = do_vfs_lock(filp, fl);
        unlock_kernel();
        if (status < 0)