Received: by 2002:ab2:2994:0:b0:1ef:ca3e:3cd5 with SMTP id n20csp757753lqb; Fri, 15 Mar 2024 05:58:45 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXCT9BuQYWb5Uy7bXwywx+maVi4y6rnu8d6Wj7EqqsVsboSblwtVPA83XpIQa7mlDNZaV0yZ9tyYdVId3LExvEm/OBQsFIE3CET3asYew== X-Google-Smtp-Source: AGHT+IFYIxw26MhAi4uqo90NXWwpIZEQdgcgIKlg0Srvrixb/UcY0ygax+RwPhGR9l4CLAuuvRJj X-Received: by 2002:a05:6902:1346:b0:dce:2e9:a637 with SMTP id g6-20020a056902134600b00dce02e9a637mr2578218ybu.20.1710507524978; Fri, 15 Mar 2024 05:58:44 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710507524; cv=pass; d=google.com; s=arc-20160816; b=IY3iV28dVLSKdyqh8+ILC68EOtG67nv+OLmxKjcuyrX9iz7uInJRN6EVOxBaUABvvz DjrpNOQrBXRZiLjj00+ps7V01/xIZejKx90k6t6W9vZfKaXkjl6hHzVG2YwDND86R7J6 2UNPiiD9NXke8vzioQi0CTTVg5xonwJp4zEJ8rc+1D3gfmaieHcBp+W9pvmBFY37r7+t 0mJSlD4edQjeoadvGa7I3sWAGm30iohWLvl0grOnZQ1VZpjmGPMVyGnCcYuLV51B8aTM jDp1AoF5sJHbYdOFKjUu0SM4sRBEifh7ALUCQ+ntM0SBQ5GtryQXwx2oOUtufhI1o+PK kXrQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:user-agent:date:message-id:from :references:cc:to:subject; bh=D8plENmeJpD4Tvjq+EAfMvO/jBolA3rwkFkaA/NhIU8=; fh=1KzA4FnDsrUVXz4EG2uub2ZCrMrerkDxv80+sQP3iG0=; b=DZm/Fbo57td06MupENfcMDfYaE7D60lrOva/MR32qwRblLDt9UZXQyspNN9m93cxEI ZR08V12qjqBQn7IDQAlbiLcLKaE6wAZra/vtdWTd3f4FRV5soHuDAB0zsBcqsh83AJWC 1jPiezkY0fiNyVIjU7kPKLRsy/MYSRsHzMmcrfhRsaZuRO41bGaRwWDX1tTQbw0IRf7X bhXHIPwdl6dHHUk0eirBUQNKRYZ5mbTfaolpYI4wfkwfHBmuIEwwEXLgzv77fbuzrJNp hkI0x4Oc2lyG8AR/8GPpxqNHaCX3HON2stXfJhXCOfbDZAO2PoOAi17WxFTFLq1WIKbN OGSQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-104418-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-104418-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=QUARANTINE) header.from=huawei.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id d21-20020a05622a101500b0042e4b1c5ccesi3531806qte.399.2024.03.15.05.58.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Mar 2024 05:58:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-104418-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-104418-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-104418-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=QUARANTINE) header.from=huawei.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id AF72C1C222F4 for ; Fri, 15 Mar 2024 12:58:44 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id ADD4428E31; Fri, 15 Mar 2024 12:58:40 +0000 (UTC) Received: from szxga05-in.huawei.com (szxga05-in.huawei.com [45.249.212.191]) (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 5079F288CF for ; Fri, 15 Mar 2024 12:58:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.191 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710507520; cv=none; b=IPtQy0EJJzbgU4UxBlWXCkOsssRE1h9Vvmpa1HNFm4Kv+RQayxmSOXofipncXvUxntJK8+Is7tQy+0jP7rct2Bv/PLjw+hpCQyhWRWHWBFDMixL7xXj8dplUWMNs7pemF0OahECBV2xgOJz0+3dnoxuQwRls4XtfQ+7O6OL8oDw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710507520; c=relaxed/simple; bh=doKKCEW0xAcyKzV3gycR+dcCOcAuhLAAPj+/A0V/+YI=; h=Subject:To:CC:References:From:Message-ID:Date:MIME-Version: In-Reply-To:Content-Type; b=UGyiZtrbPl9enxSxOMtsDZIyPXwMv9UYlL1QjfmoJSAPtyWe2tzesIV2/SNbLT9CqgFWZE58uMx0893GCqVpykKq2ph5D3Sd0mG06HP6LnucxUhR5kxsycPENw34dYSfW0+H8Z+luqWchDfjJfNUMPLDWo6NM50hFfcIEgpyvS8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.191 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.88.234]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4Tx46p4dRSz1FMCq; Fri, 15 Mar 2024 20:58:10 +0800 (CST) Received: from kwepemm600013.china.huawei.com (unknown [7.193.23.68]) by mail.maildlp.com (Postfix) with ESMTPS id 945701402CC; Fri, 15 Mar 2024 20:58:28 +0800 (CST) Received: from [10.174.178.46] (10.174.178.46) by kwepemm600013.china.huawei.com (7.193.23.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Fri, 15 Mar 2024 20:58:27 +0800 Subject: Re: [RFC PATCH] jffs2: fix recursive fs_reclaim deadlock To: Qingfang Deng CC: David Woodhouse , Richard Weinberger , , References: <20240315075946.587679-1-dqfext@gmail.com> From: Zhihao Cheng Message-ID: Date: Fri, 15 Mar 2024 20:58:27 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To kwepemm600013.china.huawei.com (7.193.23.68) 在 2024/3/15 20:19, Qingfang Deng 写道: > Hi Zhihao, > > On Fri, Mar 15, 2024 at 7:19 PM Zhihao Cheng wrote: >> I think it's a false positive warning. Jffs2 is trying to get root inode >> in process '#1', which means that the filesystem is not mounted >> yet(Because d_make_root is after jffs2_iget(sb,1), there is no way to >> access other inodes.), so it is impossible that jffs2 inode is being >> evicted in '#0'. >> > > You're right that process '#1' is getting the root inode. However, > lockdep only records the stack of the first unique lock ordering (see > https://docs.kernel.org/locking/lockdep-design.html#performance ), and > there are many occasions where GFP_KERNEL is used inside a > jffs2_inode_info::sem 's critical section. > . > Allocating memory without GFP_NOFS flags under sleeping lock is a normal thing. The vfs_write is an example(eg. ext4), page is allocated with FGP_WRITEBEGIN flag(no FGP_NOFS) when holding inode lock.