projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4a1e2fe
)
NFSv4.1/pnfs: Don't ask for a read layout for an empty file.
author
Trond Myklebust
<trond.myklebust@primarydata.com>
Mon, 31 Aug 2015 08:25:11 +0000
(
01:25
-0700)
committer
Trond Myklebust
<trond.myklebust@primarydata.com>
Mon, 31 Aug 2015 08:33:12 +0000
(
01:33
-0700)
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
fs/nfs/pnfs.c
patch
|
blob
|
history
diff --git
a/fs/nfs/pnfs.c
b/fs/nfs/pnfs.c
index 4eec540de9ea06bd95f6c6f0c9395c1e59214823..c4f918eca3d26d310fa65cdf9a11cec7c586bb45 100644
(file)
--- a/
fs/nfs/pnfs.c
+++ b/
fs/nfs/pnfs.c
@@
-1494,6
+1494,9
@@
pnfs_update_layout(struct inode *ino,
if (!pnfs_enabled_sb(NFS_SERVER(ino)))
goto out;
+ if (iomode == IOMODE_READ && i_size_read(ino) == 0)
+ goto out;
+
if (pnfs_within_mdsthreshold(ctx, ino, iomode))
goto out;