Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3419536yba; Tue, 16 Apr 2019 10:56:49 -0700 (PDT) X-Google-Smtp-Source: APXvYqyjCJ+y8SQDm8Z2P4NQPnfc30Sr7O9CxsNq9FjX/trJCOw5WO51otwyl0qL9+3fwwhHZBd8 X-Received: by 2002:a17:902:e302:: with SMTP id cg2mr80316347plb.285.1555437409782; Tue, 16 Apr 2019 10:56:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555437409; cv=none; d=google.com; s=arc-20160816; b=CDGXXcgbvyacqZqVUVUGnhKb5gyj/5T7DWMOcgP4HSsPuIXR6gGyjPT0oqYjuAYsaD +GLxNT1LgpRvUJ/R0A+lvFYpg0S079g992n4S9Qy9yaGWcoXuE4w3MtQj1qOZjHe4QVQ yj1L4xsKF/haTubZYMVSbZ1KNdtlI09ewIXuS69+LygCqhjT1xN9+L6e9/51gc0SOa1m 9vJ7PERqYsYj7mE7XY8sg63+344VMIP+SFjNamWfjchjM237tie7H+xswJboWBZ9zu/x lWt1nTpHFo3ZQRdjbAMkbn7ou2XwvLlNpO5oQlJhLivG28DdIkgDQzsyhrUYnNPaC9dW dj4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=5jvanKiqqx27YtOSKOX0XoADM4cqJN6XSDKnrTtjBt0=; b=FS0B89X+zm2DhkqgJXAH2tQk4UJvhhwTUdDp5siACmkLR4ghBEHvnq+svpxwWICcSP 48LNZ/YgIQafcug6SiSN69ffABJCjK4e8EAUZcUPU4jcpdPZAlfuoAugvHcJw0q+LGin ioqwyX3VsqtvgStmhIDNjnY3r4E7qJo5oHa0gccSd2UpRhZbFDmMZMR0IkrnbfsIHZer xCjTodKf9CGrCIUdrDoBSbLLAS2ai34aAAP+VipXmT9QRN53Vpsu1tybAZ6o3khnr+hr 3zA86vZ8AkKfxki+AmSLDhYWT6IO+i2Mlfl3fC+obYyQUcr2iH8ePiLKdMBl0bqi33dO To2w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l12si47364280pgs.184.2019.04.16.10.56.33; Tue, 16 Apr 2019 10:56:49 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730251AbfDPRzR (ORCPT + 99 others); Tue, 16 Apr 2019 13:55:17 -0400 Received: from zeniv.linux.org.uk ([195.92.253.2]:57720 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730379AbfDPRxu (ORCPT ); Tue, 16 Apr 2019 13:53:50 -0400 Received: from viro by ZenIV.linux.org.uk with local (Exim 4.92 #3 (Red Hat Linux)) id 1hGSHE-0005aT-VT; Tue, 16 Apr 2019 17:53:49 +0000 From: Al Viro To: Linus Torvalds Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: [RFC PATCH 60/62] orangefs: make use of ->free_inode() Date: Tue, 16 Apr 2019 18:53:38 +0100 Message-Id: <20190416175340.21068-60-viro@ZenIV.linux.org.uk> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190416175340.21068-1-viro@ZenIV.linux.org.uk> References: <20190416174900.GT2217@ZenIV.linux.org.uk> <20190416175340.21068-1-viro@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Al Viro Signed-off-by: Al Viro --- fs/orangefs/super.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/fs/orangefs/super.c b/fs/orangefs/super.c index dfaee90d30bd..3784f7e8b603 100644 --- a/fs/orangefs/super.c +++ b/fs/orangefs/super.c @@ -124,11 +124,9 @@ static struct inode *orangefs_alloc_inode(struct super_block *sb) return &orangefs_inode->vfs_inode; } -static void orangefs_i_callback(struct rcu_head *head) +static void orangefs_free_inode(struct inode *inode) { - struct inode *inode = container_of(head, struct inode, i_rcu); - struct orangefs_inode_s *orangefs_inode = ORANGEFS_I(inode); - kmem_cache_free(orangefs_inode_cache, orangefs_inode); + kmem_cache_free(orangefs_inode_cache, ORANGEFS_I(inode)); } static void orangefs_destroy_inode(struct inode *inode) @@ -138,8 +136,6 @@ static void orangefs_destroy_inode(struct inode *inode) gossip_debug(GOSSIP_SUPER_DEBUG, "%s: deallocated %p destroying inode %pU\n", __func__, orangefs_inode, get_khandle_from_ino(inode)); - - call_rcu(&inode->i_rcu, orangefs_i_callback); } /* @@ -299,6 +295,7 @@ void fsid_key_table_finalize(void) static const struct super_operations orangefs_s_ops = { .alloc_inode = orangefs_alloc_inode, + .free_inode = orangefs_free_inode, .destroy_inode = orangefs_destroy_inode, .drop_inode = generic_delete_inode, .statfs = orangefs_statfs, -- 2.11.0