Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp4864227iog; Wed, 22 Jun 2022 07:17:11 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uVE+NCvuh5v70SJtyJGFcHQ+DRuhCOgX/mUhV6xOggN2WyNIKwNjrIjSxr5c+/Bw0gj/mM X-Received: by 2002:a63:3606:0:b0:40d:677:8815 with SMTP id d6-20020a633606000000b0040d06778815mr3259544pga.212.1655907431405; Wed, 22 Jun 2022 07:17:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655907431; cv=none; d=google.com; s=arc-20160816; b=o4FrgYHnZQ7Ja5GsrUTshE95wNfkbz0V0kqDhS23mDUhK3is/t/hJSaHVxz46l1Bm8 BbTp7sF/X7nv8XrTuIQEaMjiRCfg3fRjLB43RkeyzYh5wTKzm48BP0ZDGajofE7rJF3Z gUm5LgnFc+Vu4wtgdCGreXZV+59NvJXj+nLZjGUKx9YGmydc24KYNEe5hgyGfWXfNrTR maSIas97vB2HDg+eiJaYoRUtDXe1NxErGFvyigUFVyWrwV3EDHnvb0x+GKbyocEloQmH HFgqnLNZWRthSgnumFp/dZCOeJY1diO94Yjd2tX3LLd7DkGnJWkpa61X0Hi8CrzUGcWC uQYg== 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:cc:to:from :subject; bh=D51GsT5NSA25KnF6snz2uCMCCBXwZ+r83rIP3mM0ZNs=; b=yC44auJLznJBDTZDvAnJqxSEol+RMCowZQHa/RlvlLeRqvW6SO4qGcd3rmv4oyQjeB NlJgVAiQwQat2+a/VDM7itjPXJsSwRO9TveTpGFJN/S+Qo75yI+BSCTBdQIriK/xlNl+ h7BmGQESVnO3SeN4Z9Tm1pHusv0mJRRazjNt2xTZP1gGIn7DQtViFnIaFamwGq8vEaoh /77XZhwDCJ7DQVAEJQcS1o/VvLcU0Bkr5jlzXUGVjOs5eGg1lcuBuXl6Eb/NL3vS9/UP ZEGOnTGIuJZVic36rCatnr7pD2WeX2tEkIRPjoAAHsPtMJo2IkTcbrUqlE9Kt3bLWPwG ufzw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 4-20020a631444000000b003fcb1ba3c4fsi21363621pgu.313.2022.06.22.07.16.59; Wed, 22 Jun 2022 07:17:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-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; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1358221AbiFVOQ0 (ORCPT + 99 others); Wed, 22 Jun 2022 10:16:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1358350AbiFVOPw (ORCPT ); Wed, 22 Jun 2022 10:15:52 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1BD673AA5A; Wed, 22 Jun 2022 07:15:20 -0700 (PDT) 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 ACBF061B71; Wed, 22 Jun 2022 14:15:19 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B7D86C34114; Wed, 22 Jun 2022 14:15:18 +0000 (UTC) Subject: [PATCH RFC 23/30] NFSD: Remove nfsd_file::nf_hashval From: Chuck Lever To: linux-nfs@vger.kernel.org, netdev@vger.kernel.org Cc: david@fromorbit.com, tgraf@suug.ch, jlayton@redhat.com Date: Wed, 22 Jun 2022 10:15:17 -0400 Message-ID: <165590731768.75778.13215851212066950275.stgit@manet.1015granger.net> In-Reply-To: <165590626293.75778.9843437418112335153.stgit@manet.1015granger.net> References: <165590626293.75778.9843437418112335153.stgit@manet.1015granger.net> User-Agent: StGit/1.5.dev2+g9ce680a5 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,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-nfs@vger.kernel.org The value in this field can always be computed from nf_inode, thus it is no longer used. Signed-off-by: Chuck Lever --- fs/nfsd/filecache.c | 6 ++---- fs/nfsd/filecache.h | 1 - 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/fs/nfsd/filecache.c b/fs/nfsd/filecache.c index fa793413bc1f..23c51b95d2a2 100644 --- a/fs/nfsd/filecache.c +++ b/fs/nfsd/filecache.c @@ -169,8 +169,7 @@ nfsd_file_mark_find_or_create(struct nfsd_file *nf) } static struct nfsd_file * -nfsd_file_alloc(struct inode *inode, unsigned int may, unsigned int hashval, - struct net *net) +nfsd_file_alloc(struct inode *inode, unsigned int may, struct net *net) { struct nfsd_file *nf; @@ -184,7 +183,6 @@ nfsd_file_alloc(struct inode *inode, unsigned int may, unsigned int hashval, nf->nf_net = net; nf->nf_flags = 0; nf->nf_inode = inode; - nf->nf_hashval = hashval; refcount_set(&nf->nf_ref, 1); nf->nf_may = may & NFSD_FILE_MAY_MASK; if (may & NFSD_MAY_NOT_BREAK_LEASE) { @@ -1009,7 +1007,7 @@ nfsd_do_file_acquire(struct svc_rqst *rqstp, struct svc_fh *fhp, if (nf) goto wait_for_construction; - new = nfsd_file_alloc(inode, may_flags, hashval, net); + new = nfsd_file_alloc(inode, may_flags, net); if (!new) { status = nfserr_jukebox; goto out_status; diff --git a/fs/nfsd/filecache.h b/fs/nfsd/filecache.h index d0c42619dc10..31dc65f82c75 100644 --- a/fs/nfsd/filecache.h +++ b/fs/nfsd/filecache.h @@ -42,7 +42,6 @@ struct nfsd_file { #define NFSD_FILE_REFERENCED (4) unsigned long nf_flags; struct inode *nf_inode; - unsigned int nf_hashval; refcount_t nf_ref; unsigned char nf_may; struct nfsd_file_mark *nf_mark;