Thread (13 messages) 13 messages, 5 authors, 2022-02-04

Re: [PATCH v3] mm: fix race between MADV_FREE reclaim and blkdev direct IO read

From: Andrew Morton <akpm@linux-foundation.org>
Date: 2022-01-31 23:43:44
Also in: linux-mm

On Mon, 31 Jan 2022 20:02:55 -0300 Mauricio Faria de Oliveira [off-list ref] wrote:
Problem:
=======

Userspace might read the zero-page instead of actual data from a
direct IO read on a block device if the buffers have been called
madvise(MADV_FREE) on earlier (this is discussed below) due to a
race between page reclaim on MADV_FREE and blkdev direct IO read.

...

Fixes: 802a3a92ad7a ("mm: reclaim MADV_FREE pages")
Five years ago.  As it doesn't seem urgent I targeted 5.18-rc1 for
this, and added a cc:stable so it will trickle back into earlier trees.

How does this plan sound?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help