Whamcloud - gitweb
EX-8421 llite: disable kernel readahead for pcc mmap
authorPatrick Farrell <pfarrell@whamcloud.com>
Tue, 17 Oct 2023 14:54:13 +0000 (10:54 -0400)
committerAndreas Dilger <adilger@whamcloud.com>
Sat, 21 Oct 2023 17:39:40 +0000 (17:39 +0000)
commit3a701bf587a66774a3138f4f8701a2d516c8cd3e
treeea55fc0ccc85209ecead2b535c86013ce3db1740
parentdfc22cde5ef2f0b286f0c897cda3e3523239a414
EX-8421 llite: disable kernel readahead for pcc mmap

Set ra_pages to 0 for PCC files when mmaped, because
otherwise this setting carries through to Lustre and will
cause crashes and possible inconsistencies.  This happens
because the PCC file and Lustre file share a mapping, which
is a weird trick required to have mmap work on PCC.

Add a set of asserts which confirm kernel readahead is
disabled and wasn't used for mmap.

Signed-off-by: Patrick Farrell <pfarrell@whamcloud.com>
Change-Id: I117042d68fac25158e8141c243acba698cf1930f
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/52732
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Qian Yingjin <qian@ddn.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
lustre/llite/pcc.c
lustre/llite/rw.c