diff options
author | Steve French <sfrench@us.ibm.com> | 2007-12-30 23:21:29 -0500 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2007-12-30 23:21:29 -0500 |
commit | bb5a9a04d4cab4b13d63ac5cd3e1fb35f9583607 (patch) | |
tree | 96d6aa52820f1e615c4a906d0ecee408d46615aa /fs/cifs/file.c | |
parent | 1a67570c76402b36695cd0725e28649ee8fe830d (diff) |
[CIFS] cifs_partialpagewrite() cleanup
rc cannot be -EBADF now and condition is always true
Signed-off-by: Vasily Averin <vvs@sw.ru>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/file.c')
-rw-r--r-- | fs/cifs/file.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/fs/cifs/file.c b/fs/cifs/file.c index dd26e2759b17..5f7c374ae89c 100644 --- a/fs/cifs/file.c +++ b/fs/cifs/file.c | |||
@@ -1179,12 +1179,10 @@ static int cifs_partialpagewrite(struct page *page, unsigned from, unsigned to) | |||
1179 | atomic_dec(&open_file->wrtPending); | 1179 | atomic_dec(&open_file->wrtPending); |
1180 | /* Does mm or vfs already set times? */ | 1180 | /* Does mm or vfs already set times? */ |
1181 | inode->i_atime = inode->i_mtime = current_fs_time(inode->i_sb); | 1181 | inode->i_atime = inode->i_mtime = current_fs_time(inode->i_sb); |
1182 | if ((bytes_written > 0) && (offset)) { | 1182 | if ((bytes_written > 0) && (offset)) |
1183 | rc = 0; | 1183 | rc = 0; |
1184 | } else if (bytes_written < 0) { | 1184 | else if (bytes_written < 0) |
1185 | if (rc != -EBADF) | 1185 | rc = bytes_written; |
1186 | rc = bytes_written; | ||
1187 | } | ||
1188 | } else { | 1186 | } else { |
1189 | cFYI(1, ("No writeable filehandles for inode")); | 1187 | cFYI(1, ("No writeable filehandles for inode")); |
1190 | rc = -EIO; | 1188 | rc = -EIO; |