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

Commit bc23676c authored by Trond Myklebust's avatar Trond Myklebust Committed by Anna Schumaker
Browse files

NFSv4.1/pnfs: Ensure we handle delegation errors in nfs4_proc_layoutget()



nfs4_handle_exception() relies on the caller setting the 'inode' field
in the struct nfs4_exception argument when the error applies to a
delegation.

Signed-off-by: default avatarTrond Myklebust <trond.myklebust@primarydata.com>
Reviewed-by: default avatarJeff Layton <jlayton@poochiereds.net>
Signed-off-by: default avatarAnna Schumaker <Anna.Schumaker@Netapp.com>
parent 33688abb
Loading
Loading
Loading
Loading
+4 −1
Original line number Original line Diff line number Diff line
@@ -8036,7 +8036,10 @@ nfs4_proc_layoutget(struct nfs4_layoutget *lgp, long *timeout, gfp_t gfp_flags)
		.flags = RPC_TASK_ASYNC,
		.flags = RPC_TASK_ASYNC,
	};
	};
	struct pnfs_layout_segment *lseg = NULL;
	struct pnfs_layout_segment *lseg = NULL;
	struct nfs4_exception exception = { .timeout = *timeout };
	struct nfs4_exception exception = {
		.inode = inode,
		.timeout = *timeout,
	};
	int status = 0;
	int status = 0;


	dprintk("--> %s\n", __func__);
	dprintk("--> %s\n", __func__);