Received: by 2002:a05:7412:518d:b0:e2:908c:2ebd with SMTP id fn13csp545308rdb; Thu, 5 Oct 2023 13:40:24 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHX+vrIqeGodPsMTkZAseLvEO4TSOxJuJ1C6MXDMoqi/AmSo68LjWS7+lC9u2ANW6FBvNAh X-Received: by 2002:a17:902:ce8a:b0:1c5:ecfb:b69e with SMTP id f10-20020a170902ce8a00b001c5ecfbb69emr6722658plg.56.1696538423857; Thu, 05 Oct 2023 13:40:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696538423; cv=none; d=google.com; s=arc-20160816; b=yeSzoXznvh4E5Uyd0LmmanXoaS1B+McDl+N/xe/Xt9E2udymk9PRkeyUednk/shBvB EF6jQiI4YBKGaFIyUZ2XZmsCyqI26o2AcARGCpM0COJbZ35T7MADFYkX+aASVrmkOV7C 5JcrWf1x5lnUKT0Ou/mTnVpRGqiPEuhdoYy+7lpJ2AZ2yAO+qpH/lVn6OetkmxxG4+7A G7wrPrbAOhL6uWzdsIK0BdOTsOwprJxhkqHdI7RAFSdEjsWOK8WpPaHavpcjt90c0I1T lmkD+nWb+f38X5jua/zZ1Y5/bN7CNUsxWMww9x0wJmTI0+ur+iz6j3tUnuqHxobfsXyC sWgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=zZCvcvIeUo1+qW/WZETpNb7eOKkcLmB0hcFt+g1D0CE=; fh=eXFvuwaYefJOmpKnHYn2Wjb2eTuogwJzhuwtyI1ia1M=; b=g8WXHBKr7I45oJH1Y5+0J7dMRQm4zTx690MmdVbzXv0d249s/BZNbEXVjBHiCXFM0z VIlPSia0RtNqyXIaxfG5DwrMOSc1tOnipuKaiwsN1qkfCO3YEt8DdyDUrwhiLMA/PBdh bwn6/w9xrqq/++A6hLPe3UV1e1GsGeWe15xI1eqrEAZujRoGF8++45KIKVtRtLQjNOng jFlULRh3p+gHIvEVUyR7rhskyt2eM+EqOm/yVjFaibwaRV5lLr3TIch7QMNj5i/MdLzl j3Wg0WjwfL/ix/ndAfUxNLiCcMC1E9BmMhgY10nJmkgsyM7jFvJ1cZi6yi/wLL0xwF1j ycdA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=X6QRxBkm; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id kq12-20020a170903284c00b001c3aed2db5dsi2114503plb.409.2023.10.05.13.40.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Oct 2023 13:40:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=X6QRxBkm; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id C62B482D9821; Thu, 5 Oct 2023 13:40:18 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229852AbjJEUkS (ORCPT + 99 others); Thu, 5 Oct 2023 16:40:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32888 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229687AbjJEUkR (ORCPT ); Thu, 5 Oct 2023 16:40:17 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2791B95; Thu, 5 Oct 2023 13:40:16 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id ACBEDC433CB; Thu, 5 Oct 2023 20:40:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1696538415; bh=mW1UI3u88BsWwD9VAiLaVyhING6a02v02PCJjmQjewU=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=X6QRxBkmmaBoBQTnjkrSp2OKJSiQaqShHMBq8TeHmoq1VhIQNvfFw+JyazjaOaVIm aD2ZLI5p/7+fftlhO/ZjJOdeHFeH1rxeuHDfAf8PMLROFmctwtkOTzpfTGC10lueYe Tr3HlgtXg3lViFrx1/5tRnfV8BL2FAST0G0KO/bZJ/Ft3L8TsH/xBzNYx3r1mEAev4 O1dCSRfEqi43ip4N9d7gX0RXSd6NrvJrFP0/jo2geCivuDX7QvqVYaCz7Lp4346Hv8 aZsY6oG5uZH8+hTtqHUjMe1YQkptddTzT2rUcD+Lf+viLGo/sD7ekLwHbyBtyz6gcg cnc+YPijfsYoQ== Received: by mail-qt1-f182.google.com with SMTP id d75a77b69052e-419cc494824so6905131cf.2; Thu, 05 Oct 2023 13:40:15 -0700 (PDT) X-Gm-Message-State: AOJu0Yx3h0TBQgNHVhkHWPU7uuE3N6buDSRU7WgeE+Wgasrfx9BLngeh eCntkqaCTblT3k/mAKzDbNMgWQJwTWSp4emNUQ8= X-Received: by 2002:a05:622a:104e:b0:419:51db:5c with SMTP id f14-20020a05622a104e00b0041951db005cmr7546095qte.32.1696538414712; Thu, 05 Oct 2023 13:40:14 -0700 (PDT) MIME-Version: 1.0 References: <5577791deaa898578c8e8f86336eaca053d9efdd.1687890438.git.bcodding@redhat.com> In-Reply-To: <5577791deaa898578c8e8f86336eaca053d9efdd.1687890438.git.bcodding@redhat.com> From: Anna Schumaker Date: Thu, 5 Oct 2023 16:39:58 -0400 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 1/2] Revert "NFSv4: Retry LOCK on OLD_STATEID during delegation return" To: stable@vger.kernel.org Cc: trond.myklebust@hammerspace.com, Olga.Kornievskaia@netapp.com, linux-nfs@vger.kernel.org, Benjamin Coddington Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Thu, 05 Oct 2023 13:40:19 -0700 (PDT) Hi Stable Kernel Team, Can this patch be backported to v6.1+ kernels? The commit id is 5b4a82a0724a and has been upstream since v6.5. As was mentioned in the original patch description (below), the commit being reverted by this patch breaks state recovery in a way that is worse than the initial bug that it was attempting to fix. Thanks, Anna On Tue, Jun 27, 2023 at 2:31=E2=80=AFPM Benjamin Coddington wrote: > > Olga Kornievskaia reports that this patch breaks NFSv4.0 state recovery. > It also introduces additional complexity in the error paths for cases not > related to the original problem. Let's revert it for now, and address th= e > original problem in another manner. > > This reverts commit f5ea16137a3fa2858620dc9084466491c128535f. > > Fixes: f5ea16137a3f ("NFSv4: Retry LOCK on OLD_STATEID during delegation = return") > Reported-by: Kornievskaia, Olga > Signed-off-by: Benjamin Coddington > --- > fs/nfs/nfs4proc.c | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c > index d3665390c4cb..6bb14f6cfbc0 100644 > --- a/fs/nfs/nfs4proc.c > +++ b/fs/nfs/nfs4proc.c > @@ -7159,7 +7159,6 @@ static void nfs4_lock_done(struct rpc_task *task, v= oid *calldata) > { > struct nfs4_lockdata *data =3D calldata; > struct nfs4_lock_state *lsp =3D data->lsp; > - struct nfs_server *server =3D NFS_SERVER(d_inode(data->ctx->dentr= y)); > > if (!nfs4_sequence_done(task, &data->res.seq_res)) > return; > @@ -7167,7 +7166,8 @@ static void nfs4_lock_done(struct rpc_task *task, v= oid *calldata) > data->rpc_status =3D task->tk_status; > switch (task->tk_status) { > case 0: > - renew_lease(server, data->timestamp); > + renew_lease(NFS_SERVER(d_inode(data->ctx->dentry)), > + data->timestamp); > if (data->arg.new_lock && !data->cancelled) { > data->fl.fl_flags &=3D ~(FL_SLEEP | FL_ACCESS); > if (locks_lock_inode_wait(lsp->ls_state->inode, &= data->fl) < 0) > @@ -7188,8 +7188,6 @@ static void nfs4_lock_done(struct rpc_task *task, v= oid *calldata) > if (!nfs4_stateid_match(&data->arg.open_stateid, > &lsp->ls_state->open_stat= eid)) > goto out_restart; > - else if (nfs4_async_handle_error(task, server, ls= p->ls_state, NULL) =3D=3D -EAGAIN) > - goto out_restart; > } else if (!nfs4_stateid_match(&data->arg.lock_stateid, > &lsp->ls_stateid)) > goto out_restart; > -- > 2.40.1 >