aboutsummaryrefslogtreecommitdiffstats
path: root/mm/filemap.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2022-06-07 15:45:53 -0400
committerMatthew Wilcox (Oracle) <willy@infradead.org>2022-06-09 16:24:25 -0400
commit6bf74cddcffac0bc5ee0fad724aac778d2e53f75 (patch)
treeed0e4594baaf65b943a2a522ebcba63bcc4e69f4 /mm/filemap.c
parentMerge tag 'fs_for_v5.19-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs (diff)
downloadlinux-dev-6bf74cddcffac0bc5ee0fad724aac778d2e53f75.tar.xz
linux-dev-6bf74cddcffac0bc5ee0fad724aac778d2e53f75.zip
filemap: Don't release a locked folio
We must hold a reference over the call to filemap_release_folio(), otherwise the page cache will put the last reference to the folio before we unlock it, leading to splats like this: BUG: Bad page state in process u8:5 pfn:1ab1f4 page:ffffea0006ac7d00 refcount:0 mapcount:0 mapping:0000000000000000 index:0x28b1de pfn:0x1ab1f4 flags: 0x17ff80000040001(locked|reclaim|node=0|zone=2|lastcpupid=0xfff) raw: 017ff80000040001 dead000000000100 dead000000000122 0000000000000000 raw: 000000000028b1de 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: PAGE_FLAGS_CHECK_AT_FREE flag(s) set It's an error path, so it doesn't see much testing. Reported-by: Darrick J. Wong <djwong@kernel.org> Fixes: a42634a6c07d ("readahead: Use a folio in read_pages()") Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Diffstat (limited to 'mm/filemap.c')
0 files changed, 0 insertions, 0 deletions