From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2338F1C08 for ; Wed, 28 Dec 2022 16:30:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9B869C433D2; Wed, 28 Dec 2022 16:30:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1672245053; bh=N7E2SRwYkQ21JYEy9MXkODJLsG2TrZGxGZHcYLdxbTU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DHdF9HDDAZa2KactUxzpWkAHc4RC7WpOAjHtTOiMzGCaseBWsgnFJZSbKeWbAotTM RTl+HHkCcjVCyfMoEgb9myolFuR/TIdCYaKjoI0pCxyVQL0H/BlxUbyz4R2DFCUrMf US1SVjTsRjO5Lo7I0iLi0Gqyt/5bP27ZBYSH0leQ= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Andreas Gruenbacher , Sasha Levin Subject: [PATCH 6.1 0784/1146] gfs2: Partially revert gfs2_inode_lookup change Date: Wed, 28 Dec 2022 15:38:43 +0100 Message-Id: <20221228144351.442248574@linuxfoundation.org> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20221228144330.180012208@linuxfoundation.org> References: <20221228144330.180012208@linuxfoundation.org> User-Agent: quilt/0.67 Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Andreas Gruenbacher [ Upstream commit 88f4a9f813c549f6b8a6fbf12030949b48a4d5a4 ] Commit c412a97cf6c5 changed delete_work_func() to always perform an inode lookup when gfs2_try_evict() fails. This doesn't make sense as a gfs2_try_evict() failure indicates that the inode is likely still in use. Revert that change. Fixes: c412a97cf6c5 ("gfs2: Use TRY lock in gfs2_inode_lookup for UNLINKED inodes") Signed-off-by: Andreas Gruenbacher Signed-off-by: Sasha Levin --- fs/gfs2/glock.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c index df335c258eb0..235a0948f6cc 100644 --- a/fs/gfs2/glock.c +++ b/fs/gfs2/glock.c @@ -1039,6 +1039,7 @@ static void delete_work_func(struct work_struct *work) if (gfs2_queue_delete_work(gl, 5 * HZ)) return; } + goto out; } inode = gfs2_lookup_by_inum(sdp, no_addr, gl->gl_no_formal_ino, @@ -1051,6 +1052,7 @@ static void delete_work_func(struct work_struct *work) d_prune_aliases(inode); iput(inode); } +out: gfs2_glock_put(gl); } -- 2.35.1