From: Zhihao Cheng <chengzhihao1@huawei.com>
To: Qingfang Deng <dqfext@gmail.com>
Cc: David Woodhouse <dwmw2@infradead.org>,
Richard Weinberger <richard@nod.at>,
<linux-mtd@lists.infradead.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [RFC PATCH] jffs2: fix recursive fs_reclaim deadlock
Date: Fri, 15 Mar 2024 20:58:27 +0800 [thread overview]
Message-ID: <e5c2c285-0b10-0d23-2c02-7582c026dbfd@huawei.com> (raw)
In-Reply-To: <CALW65jbKBUDN8ybE1oqrNW5VK1QGpZ1RmnFCCzxjQCo4obaA4A@mail.gmail.com>
在 2024/3/15 20:19, Qingfang Deng 写道:
> Hi Zhihao,
>
> On Fri, Mar 15, 2024 at 7:19 PM Zhihao Cheng <chengzhihao1@huawei.com> 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.
next prev parent reply other threads:[~2024-03-15 12:58 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-15 7:59 Qingfang Deng
2024-03-15 11:19 ` Zhihao Cheng
2024-03-15 12:19 ` Qingfang Deng
2024-03-15 12:58 ` Zhihao Cheng [this message]
2024-03-19 6:41 ` Qingfang Deng
2024-03-19 7:56 ` Zhihao Cheng
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e5c2c285-0b10-0d23-2c02-7582c026dbfd@huawei.com \
--to=chengzhihao1@huawei.com \
--cc=dqfext@gmail.com \
--cc=dwmw2@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=richard@nod.at \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®