lkml.org 
[lkml]   [2022]   [Jun]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 4.19 199/234] pNFS: Dont keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE
    Date
    From: Trond Myklebust <trond.myklebust@hammerspace.com>

    [ 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: 183d9e7b112a ("pnfs: rework LAYOUTGET retry handling")
    Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
    Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
    Signed-off-by: Sasha Levin <sashal@kernel.org>
    ---
    fs/nfs/pnfs.c | 6 ++++++
    1 file changed, 6 insertions(+)

    diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c
    index a7d638bfb46b..cfb1fe5dfb1e 100644
    --- a/fs/nfs/pnfs.c
    +++ b/fs/nfs/pnfs.c
    @@ -2045,6 +2045,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));
    --
    2.35.1


    \
     
     \ /
      Last update: 2022-06-23 20:20    [W:4.898 / U:0.404 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site