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

Commit 11c870c0 authored by Trond Myklebust's avatar Trond Myklebust Committed by Greg Kroah-Hartman
Browse files

pNFS: Don't keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE



[ Upstream commit fe44fb23d6ccde4c914c44ef74ab8d9d9ba02bea ]

If the server tells us that a pNFS layout is not available for a
specific file, then we should not keep pounding it with further
layoutget requests.

Fixes: 183d9e7b ("pnfs: rework LAYOUTGET retry handling")
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: default avatarAnna Schumaker <Anna.Schumaker@Netapp.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent e32fe87a
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -2111,6 +2111,12 @@ pnfs_update_layout(struct inode *ino,
		case -ERECALLCONFLICT:
		case -EAGAIN:
			break;
		case -ENODATA:
			/* The server returned NFS4ERR_LAYOUTUNAVAILABLE */
			pnfs_layout_set_fail_bit(
				lo, pnfs_iomode_to_fail_bit(iomode));
			lseg = NULL;
			goto out_put_layout_hdr;
		default:
			if (!nfs_error_is_fatal(PTR_ERR(lseg))) {
				pnfs_layout_clear_fail_bit(lo, pnfs_iomode_to_fail_bit(iomode));