From nobody Fri Oct 17 10:32:18 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 30DFEC4332F for ; Wed, 19 Oct 2022 08:52:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231754AbiJSIwC (ORCPT ); Wed, 19 Oct 2022 04:52:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33672 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231986AbiJSIuE (ORCPT ); Wed, 19 Oct 2022 04:50:04 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D15AF2CCBF; Wed, 19 Oct 2022 01:48:46 -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 C47F2617F7; Wed, 19 Oct 2022 08:47:43 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DD1CBC433D6; Wed, 19 Oct 2022 08:47:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666169263; bh=cUStqzs1sm90x91UAWNz1rhejrC3JpfXLKWtUpHmuFQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=z5I1Rdoi7xk4jubm3idsEAuvsr8PmZxirfqOenfiktckF0EK6EJxdVVD/uh0UMaSd jlECqsrYQKDKrobBHObzQ2JG5mpoznU9y+Zqw/OgmZkqRm2YEw39w0ns6TiLxd/fNM kledWCmbWQl3PZz6lJrh6GqdIs/D/NLc1XR1EpPU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jingbo Xu , Jia Zhu , Gao Xiang , Sasha Levin Subject: [PATCH 6.0 213/862] erofs: use kill_anon_super() to kill super in fscache mode Date: Wed, 19 Oct 2022 10:25:00 +0200 Message-Id: <20221019083259.435616379@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221019083249.951566199@linuxfoundation.org> References: <20221019083249.951566199@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Jia Zhu [ Upstream commit 1015c1016c231b26d4e2c9b3da65b6c043eb97a3 ] Use kill_anon_super() instead of generic_shutdown_super() since the mount() in erofs fscache mode uses get_tree_nodev() and associated anon bdev needs to be freed. Fixes: 9c0cc9c729657 ("erofs: add 'fsid' mount option") Suggested-by: Jingbo Xu Signed-off-by: Jia Zhu Reviewed-by: Jingbo Xu Link: https://lore.kernel.org/r/20220918043456.147-2-zhujia.zj@bytedance.com Signed-off-by: Gao Xiang Signed-off-by: Sasha Levin --- fs/erofs/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/erofs/super.c b/fs/erofs/super.c index 3173debeaa5a..9716d355a63e 100644 --- a/fs/erofs/super.c +++ b/fs/erofs/super.c @@ -879,7 +879,7 @@ static void erofs_kill_sb(struct super_block *sb) WARN_ON(sb->s_magic !=3D EROFS_SUPER_MAGIC); =20 if (erofs_is_fscache_mode(sb)) - generic_shutdown_super(sb); + kill_anon_super(sb); else kill_block_super(sb); =20 --=20 2.35.1