[pnfs] [PATCH 09/10] [nfs41-2.6.25] nfs41: call nfs4_recover_expired_lease from nfs4_lookup_root

Benny Halevy bhalevy at panasas.com
Thu Mar 20 12:22:51 EDT 2008


In preparation for removing NFS4_VALIDATE_STATE, lookup_root
is being called in the mount path and it must trigger
session recovery (that generates create_session)

Signed-off-by: Benny Halevy <bhalevy at panasas.com>
---
 fs/nfs/nfs4proc.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index ae91da0..99f0e87 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -2022,9 +2022,12 @@ static int _nfs4_lookup_root(struct nfs_server *server, struct nfs_fh *fhandle,
 	nfs_fattr_init(info->fattr);
 
 	NFS4_VALIDATE_STATE(server);
+	status = nfs4_recover_expired_lease(server);
+	if (status != 0)
+		goto out;
 	status = nfs4_call_sync(server, server->client, &msg,
 				&args, &res, 0);
-
+out:
 	dprintk("<-- %s status= %d\n", __func__, status);
 	return status;
 }
-- 
1.5.3.3



More information about the pNFS mailing list