]> git.baikalelectronics.ru Git - kernel.git/commit
gfs2: Disable page faults during lockless buffered reads
authorAndreas Gruenbacher <agruenba@redhat.com>
Mon, 14 Mar 2022 17:32:02 +0000 (18:32 +0100)
committerAndreas Gruenbacher <agruenba@redhat.com>
Wed, 23 Mar 2022 15:52:41 +0000 (16:52 +0100)
commit272a242a60466a62843faeefb9e3b2a5f18129c4
tree398a3f660177b830fad71291b7741af7e8cc9a3d
parentaa6434dbf9ee564a708746a840229da1c390409d
gfs2: Disable page faults during lockless buffered reads

During lockless buffered reads, filemap_read() holds page cache page
references while trying to copy data to the user-space buffer.  The
calling process isn't holding the inode glock, but the page references
it holds prevent those pages from being removed from the page cache, and
that prevents the underlying inode glock from being moved to another
node.  Thus, we can end up in the same kinds of distributed deadlock
situations as with normal (non-lockless) buffered reads.

Fix that by disabling page faults during lockless reads as well.

Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/file.c