Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7d6d63d6 authored by Ricardo Labiaga's avatar Ricardo Labiaga Committed by Trond Myklebust
Browse files

NFSv4.1: Retry CREATE_SESSION on NFS4ERR_DELAY



Fix bug where we currently retry the EXCHANGEID call again, eventhough
we already have a valid clientid.  Instead, delay and retry the CREATE_SESSION
call.

Signed-off-by: default avatarRicardo Labiaga <Ricardo.Labiaga@netapp.com>
Signed-off-by: default avatarTrond Myklebust <Trond.Myklebust@netapp.com>
parent 4cea288a
Loading
Loading
Loading
Loading
+11 −1
Original line number Diff line number Diff line
@@ -5028,10 +5028,20 @@ int nfs4_proc_create_session(struct nfs_client *clp)
	int status;
	unsigned *ptr;
	struct nfs4_session *session = clp->cl_session;
	long timeout = 0;
	int err;

	dprintk("--> %s clp=%p session=%p\n", __func__, clp, session);

	do {
		status = _nfs4_proc_create_session(clp);
		if (status == -NFS4ERR_DELAY) {
			err = nfs4_delay(clp->cl_rpcclient, &timeout);
			if (err)
				status = err;
		}
	} while (status == -NFS4ERR_DELAY);

	if (status)
		goto out;