Received: by 2002:a05:6a10:7420:0:0:0:0 with SMTP id hk32csp3919391pxb; Mon, 21 Feb 2022 08:18:45 -0800 (PST) X-Google-Smtp-Source: ABdhPJwGLw9NpnzvjtOnl3ppVT3AstNpjlCIFl8dquBUj54QmK5dDNpzIC0XxiWYXK2AQCOTjDBe X-Received: by 2002:a63:f011:0:b0:36c:2da3:32bc with SMTP id k17-20020a63f011000000b0036c2da332bcmr16547360pgh.40.1645460325136; Mon, 21 Feb 2022 08:18:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645460325; cv=none; d=google.com; s=arc-20160816; b=YEFtSsTJE3CzTd+0Xe7ygLoLB8niDFA/p2dp+6TqcBSE259BYwTom7N+feaW/A21YT xtp0DZw8aHmhZeWIesOcbIDOuBpzF7l39cz1LjIAHy+pyiRwFofmEybTT/zEl4+qmjzO V3COIb3qQ7BkdJnLOkDu01sVi8jzXjot9ymxkVzjR+sKJFim26ZaQMp/mzJX+slwC+za 4Msg2oeSGWW44S+RpyB2/PoQWsa4uDt4q8EC0rsd6iHNY5wNtPrgthgEcOaRVtDvyzoQ PkFKTdbd0p4NJNoCwZvqbqF6HaKFeoNuniB9mywylV4OBhQCpF1OszEBXCFSHJBNND/3 Mqyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=baJ8gne6uGbs+l3js8FPkqRcfjZ4u3zyouuO6cilAgw=; b=s6gZLMfwlXgLr0C+P1YydhvXX4wQ4FpUuQsKi7Ro59d/Cg6pQnvw/4zlenOajeHEtM P1DOcarW5uSeKz389SqaeGztxKBt3JxtgV8nmVVQ2RgwRFj3rF8w41ePpxhCNV3PuH6a kgzydwHQ7hnuUmooDjgs7djXOlmlIYXUt1F4wFXzSfoxU9hIgDyH3Mf4PoLJ/J8UhU0F 3RaciEGaLkZxjdzsInyIxE4biCVbPmPygUD95OXFClX6D8ZQ2E+YtjcIS/3U7NvNRHQU NxE/6pyJD96yJvfql+PD+VWEkI2Xbn6u4+7as5YNHOQJj2NOCHIborsil42cOVEjEMQF Byww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Keqc9CW8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q8si10231622pfk.281.2022.02.21.08.18.28; Mon, 21 Feb 2022 08:18:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Keqc9CW8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1353557AbiBUKB4 (ORCPT + 99 others); Mon, 21 Feb 2022 05:01:56 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:55810 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1352349AbiBUJxy (ORCPT ); Mon, 21 Feb 2022 04:53:54 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3017637019; Mon, 21 Feb 2022 01:23:47 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C136E60FCC; Mon, 21 Feb 2022 09:23:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A9455C340E9; Mon, 21 Feb 2022 09:23:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1645435426; bh=uLIjypjoYN0GySrz3pbbzUIqlZoebQ0xIGjvV4tfMyQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Keqc9CW8FV7ieQx6iOzQ8pp9C+Vld67q8q/OSTTgkJ7OTc2mBweVP/8s7GPAN14td 6hvnubf9xWKW0KKdjPeU2O1gZV1Sw66Ax7MVFIBKQa+ne5VQ+4igwiRJ/887EWyp6x 7WEltP95hBW5Ssp3lYwN2lV89E1HLSFUzIjESaMo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Trond Myklebust , Anna Schumaker Subject: [PATCH 5.16 160/227] NFS: Remove an incorrect revalidation in nfs4_update_changeattr_locked() Date: Mon, 21 Feb 2022 09:49:39 +0100 Message-Id: <20220221084940.144222029@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220221084934.836145070@linuxfoundation.org> References: <20220221084934.836145070@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Trond Myklebust commit 9d047bf68fe8cdb4086deaf4edd119731a9481ed upstream. In nfs4_update_changeattr_locked(), we don't need to set the NFS_INO_REVAL_PAGECACHE flag, because we already know the value of the change attribute, and we're already flagging the size. In fact, this forces us to revalidate the change attribute a second time for no good reason. This extra flag appears to have been introduced as part of the xattr feature, when update_changeattr_locked() was converted for use by the xattr code. Fixes: 1b523ca972ed ("nfs: modify update_changeattr to deal with regular files") Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker Signed-off-by: Greg Kroah-Hartman --- fs/nfs/nfs4proc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -1233,8 +1233,7 @@ nfs4_update_changeattr_locked(struct ino NFS_INO_INVALID_ACCESS | NFS_INO_INVALID_ACL | NFS_INO_INVALID_SIZE | NFS_INO_INVALID_OTHER | NFS_INO_INVALID_BLOCKS | NFS_INO_INVALID_NLINK | - NFS_INO_INVALID_MODE | NFS_INO_INVALID_XATTR | - NFS_INO_REVAL_PAGECACHE; + NFS_INO_INVALID_MODE | NFS_INO_INVALID_XATTR; nfsi->attrtimeo = NFS_MINATTRTIMEO(inode); } nfsi->attrtimeo_timestamp = jiffies;