From: Matthew Wilcox <willy@infradead.org>
To: Hillf Danton <hdanton@sina.com>
Cc: Genes Lists <lists@sapience.com>,
linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
linux-mm@kvack.org
Subject: Re: 6.6.8 stable: crash in folio_mark_dirty
Date: Wed, 3 Jan 2024 17:53:59 +0000 [thread overview]
Message-ID: <ZZWfN6ymZ50MjzuQ@casper.infradead.org> (raw)
In-Reply-To: <20240103104907.2657-1-hdanton@sina.com>
On Wed, Jan 03, 2024 at 06:49:07PM +0800, Hillf Danton wrote:
> On Mon, 1 Jan 2024 14:11:02 +0000 Matthew Wilcox
> >
> > From an mm point of view, what is implicit is that truncate calls
> > unmap_mapping_folio -> unmap_mapping_range_tree ->
> > unmap_mapping_range_vma -> zap_page_range_single -> unmap_single_vma ->
> > unmap_page_range -> zap_p4d_range -> zap_pud_range -> zap_pmd_range ->
> > zap_pte_range -> pte_offset_map_lock()
> >
> > So a truncate will take the page lock, then spin on the pte lock
> > until the racing munmap() has finished (ok, this was an exit(), not
> > a munmap(), but exit() does an implicit munmap()).
> >
> But ptl fails to explain the warning reported, while the sequence in
> __block_commit_write()
>
> mark_buffer_dirty();
> folio_mark_uptodate();
>
> hints the warning is bogus.
The folio is locked when filesystems call __block_commit_write().
Nothing explains the reported warning, IMO. Other than data corruption,
and I'm not sure that we've found the last data corrupter.
next prev parent reply other threads:[~2024-01-03 17:54 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-30 15:23 Genes Lists
2023-12-30 18:02 ` Matthew Wilcox
2023-12-30 19:16 ` Genes Lists
2023-12-31 1:28 ` Hillf Danton
2023-12-31 13:07 ` Matthew Wilcox
2024-01-01 1:55 ` Hillf Danton
2024-01-01 9:07 ` Matthew Wilcox
2024-01-01 11:33 ` Hillf Danton
2024-01-01 14:11 ` Matthew Wilcox
2024-01-03 10:49 ` Hillf Danton
2024-01-03 17:53 ` Matthew Wilcox [this message]
2023-12-31 20:59 ` Matthew Wilcox
2023-12-31 21:12 ` Genes Lists
2023-12-31 21:15 ` Genes Lists
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=ZZWfN6ymZ50MjzuQ@casper.infradead.org \
--to=willy@infradead.org \
--cc=hdanton@sina.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lists@sapience.com \
/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