summaryrefslogtreecommitdiffstats
path: root/fs/nfs/client.c
diff options
context:
space:
mode:
authorTrond Myklebust2015-03-04 02:28:59 +0100
committerTrond Myklebust2015-03-04 02:42:23 +0100
commit48d66b9749e39e0d4cc37d635df3f18906af38a6 (patch)
treeb64b126f4b74bae8b4fd3db8d26147a2d394477f /fs/nfs/client.c
parentNFS: Don't write enable new pages while an invalidation is proceeding (diff)
downloadkernel-qcow2-linux-48d66b9749e39e0d4cc37d635df3f18906af38a6.tar.gz
kernel-qcow2-linux-48d66b9749e39e0d4cc37d635df3f18906af38a6.tar.xz
kernel-qcow2-linux-48d66b9749e39e0d4cc37d635df3f18906af38a6.zip
NFSv4: Fix a race in NFSv4.1 server trunking discovery
We do not want to allow a race with another NFS mount to cause nfs41_walk_client_list() to establish a lease on our nfs_client before we're done checking for trunking. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/client.c')
-rw-r--r--fs/nfs/client.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfs/client.c b/fs/nfs/client.c
index f9f4845db989..19874151e95c 100644
--- a/fs/nfs/client.c
+++ b/fs/nfs/client.c
@@ -433,7 +433,7 @@ static struct nfs_client *nfs_match_client(const struct nfs_client_initdata *dat
static bool nfs_client_init_is_complete(const struct nfs_client *clp)
{
- return clp->cl_cons_state != NFS_CS_INITING;
+ return clp->cl_cons_state <= NFS_CS_READY;
}
int nfs_wait_client_init_complete(const struct nfs_client *clp)