diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-11-04 15:27:43 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-11-04 15:27:43 -0400 |
commit | 6736c047995c560b73f3860095c631456b0bbea8 (patch) | |
tree | 1ef4d2ab9d7d2f2cd3fe26a3e9135fb312e81b85 /fs/nfs/file.c | |
parent | 16dfd1faed8c5235d9a7c190b91b6d97d6cd3272 (diff) | |
parent | 6070295efc90d1093b2031c43380bd7d9673c802 (diff) |
Merge branch 'nfs-for-3.2' of git://git.linux-nfs.org/projects/trondmy/linux-nfs
* 'nfs-for-3.2' of git://git.linux-nfs.org/projects/trondmy/linux-nfs: (25 commits)
nfs: set vs_hidden on nfs4_callback_version4 (try #2)
pnfs-obj: Support for RAID5 read-4-write interface.
pnfs-obj: move to ore 03: Remove old raid engine
pnfs-obj: move to ore 02: move to ORE
pnfs-obj: move to ore 01: ore_layout & ore_components
pnfs-obj: Rename objlayout_io_state => objlayout_io_res
pnfs-obj: Get rid of objlayout_{alloc,free}_io_state
pnfs-obj: Return PNFS_NOT_ATTEMPTED in case of read/write_pagelist
pnfs-obj: Remove redundant EOF from objlayout_io_state
nfs: Remove unused variable from write.c
nfs: Fix unused variable warning from file.c
NFS: Remove no-op less-than-zero checks on unsigned variables.
NFS: Clean up nfs4_xdr_dec_secinfo()
NFS: Fix documenting comment for nfs_create_request()
NFS4: fix cb_recallany decode error
nfs4: serialize layoutcommit
SUNRPC: remove rpcbind clients destruction on module cleanup
SUNRPC: remove rpcbind clients creation during service registering
NFSd: call svc rpcbind cleanup explicitly
SUNRPC: cleanup service destruction
...
Diffstat (limited to 'fs/nfs/file.c')
-rw-r--r-- | fs/nfs/file.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/nfs/file.c b/fs/nfs/file.c index 91c01f0a4c3b..0a1f8312b4dc 100644 --- a/fs/nfs/file.c +++ b/fs/nfs/file.c | |||
@@ -137,11 +137,9 @@ nfs_file_open(struct inode *inode, struct file *filp) | |||
137 | static int | 137 | static int |
138 | nfs_file_release(struct inode *inode, struct file *filp) | 138 | nfs_file_release(struct inode *inode, struct file *filp) |
139 | { | 139 | { |
140 | struct dentry *dentry = filp->f_path.dentry; | ||
141 | |||
142 | dprintk("NFS: release(%s/%s)\n", | 140 | dprintk("NFS: release(%s/%s)\n", |
143 | dentry->d_parent->d_name.name, | 141 | filp->f_path.dentry->d_parent->d_name.name, |
144 | dentry->d_name.name); | 142 | filp->f_path.dentry->d_name.name); |
145 | 143 | ||
146 | nfs_inc_stats(inode, NFSIOS_VFSRELEASE); | 144 | nfs_inc_stats(inode, NFSIOS_VFSRELEASE); |
147 | return nfs_release(inode, filp); | 145 | return nfs_release(inode, filp); |
@@ -228,14 +226,13 @@ nfs_file_read(struct kiocb *iocb, const struct iovec *iov, | |||
228 | struct dentry * dentry = iocb->ki_filp->f_path.dentry; | 226 | struct dentry * dentry = iocb->ki_filp->f_path.dentry; |
229 | struct inode * inode = dentry->d_inode; | 227 | struct inode * inode = dentry->d_inode; |
230 | ssize_t result; | 228 | ssize_t result; |
231 | size_t count = iov_length(iov, nr_segs); | ||
232 | 229 | ||
233 | if (iocb->ki_filp->f_flags & O_DIRECT) | 230 | if (iocb->ki_filp->f_flags & O_DIRECT) |
234 | return nfs_file_direct_read(iocb, iov, nr_segs, pos); | 231 | return nfs_file_direct_read(iocb, iov, nr_segs, pos); |
235 | 232 | ||
236 | dprintk("NFS: read(%s/%s, %lu@%lu)\n", | 233 | dprintk("NFS: read(%s/%s, %lu@%lu)\n", |
237 | dentry->d_parent->d_name.name, dentry->d_name.name, | 234 | dentry->d_parent->d_name.name, dentry->d_name.name, |
238 | (unsigned long) count, (unsigned long) pos); | 235 | (unsigned long) iov_length(iov, nr_segs), (unsigned long) pos); |
239 | 236 | ||
240 | result = nfs_revalidate_mapping(inode, iocb->ki_filp->f_mapping); | 237 | result = nfs_revalidate_mapping(inode, iocb->ki_filp->f_mapping); |
241 | if (!result) { | 238 | if (!result) { |