]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commitdiff
CIFS: Make ops->close return void
authorPavel Shilovsky <piastry@etersoft.ru>
Tue, 25 Sep 2012 07:00:07 +0000 (11:00 +0400)
committerSteve French <smfrench@gmail.com>
Thu, 27 Sep 2012 03:05:10 +0000 (22:05 -0500)
Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru>
Signed-off-by: Steve French <smfrench@gmail.com>
fs/cifs/cifsglob.h
fs/cifs/file.c
fs/cifs/smb1ops.c
fs/cifs/smb2ops.c

index a39e5b7fc844628ba810f9217eff9cf2ed45498e..f6f40635abcada222f4d7aac2d60ed33d0a49dcf 100644 (file)
@@ -316,7 +316,8 @@ struct smb_version_operations {
        /* set fid protocol-specific info */
        void (*set_fid)(struct cifsFileInfo *, struct cifs_fid *, __u32);
        /* close a file */
-       int (*close)(const unsigned int, struct cifs_tcon *, struct cifs_fid *);
+       void (*close)(const unsigned int, struct cifs_tcon *,
+                     struct cifs_fid *);
        /* send a flush request to the server */
        int (*flush)(const unsigned int, struct cifs_tcon *, struct cifs_fid *);
        /* async read from the server */
index 075f7cfd1da53aecfc75f171c75e4376c9180ecb..7d7bbdc4c8e73d3ee77ae0b52f2fa589548678e9 100644 (file)
@@ -355,12 +355,11 @@ void cifsFileInfo_put(struct cifsFileInfo *cifs_file)
        if (!tcon->need_reconnect && !cifs_file->invalidHandle) {
                struct TCP_Server_Info *server = tcon->ses->server;
                unsigned int xid;
-               int rc = -ENOSYS;
 
                xid = get_xid();
                if (server->ops->close)
-                       rc = server->ops->close(xid, tcon, &cifs_file->fid);
-               free_xid(xid);
+                       server->ops->close(xid, tcon, &cifs_file->fid);
+               _free_xid(xid);
        }
 
        cifs_del_pending_open(&open);
index 5fb0fe5f72b60820aee15eedd061e536aa9545bc..42dccbb57c40e46d00ee57a9c900664a5822328e 100644 (file)
@@ -720,11 +720,11 @@ cifs_set_fid(struct cifsFileInfo *cfile, struct cifs_fid *fid, __u32 oplock)
        cinode->can_cache_brlcks = cinode->clientCanCacheAll;
 }
 
-static int
+static void
 cifs_close_file(const unsigned int xid, struct cifs_tcon *tcon,
                struct cifs_fid *fid)
 {
-       return CIFSSMBClose(xid, tcon, fid->netfid);
+       CIFSSMBClose(xid, tcon, fid->netfid);
 }
 
 static int
index 2183bb343edd157e924ea2f892ec3e42b06ea1b4..1570cbea4a499d811db0a8f6eab072ebf89dcb89 100644 (file)
@@ -374,11 +374,11 @@ smb2_set_fid(struct cifsFileInfo *cfile, struct cifs_fid *fid, __u32 oplock)
        cinode->can_cache_brlcks = cinode->clientCanCacheAll;
 }
 
-static int
+static void
 smb2_close_file(const unsigned int xid, struct cifs_tcon *tcon,
                struct cifs_fid *fid)
 {
-       return SMB2_close(xid, tcon, fid->persistent_fid, fid->volatile_fid);
+       SMB2_close(xid, tcon, fid->persistent_fid, fid->volatile_fid);
 }
 
 static int