Whamcloud - gitweb
LU-17248 kernel: wait for pages under writeback for bdev 22/52922/6
authorLi Dongyang <dongyangli@ddn.com>
Wed, 1 Nov 2023 11:36:10 +0000 (22:36 +1100)
committerOleg Drokin <green@whamcloud.com>
Sat, 23 Mar 2024 05:52:59 +0000 (05:52 +0000)
commitbceabe55b252ff14757637c5ef7ac21b49e74568
treeaed1f337cae36a30629453dd60b848a9222bf7b9
parent49f230e10d11c3560680b00a5ffba4c655cf204d
LU-17248 kernel: wait for pages under writeback for bdev

Since RHEL 8.6 wait_for_stable_page() is controlled by
a new flag SB_I_STABLE_WRITES on the super block.

However the new flag is not set on the bdev pseudo sb,
which mean when doing write directly to the block device
we are not waiting on page writeback, this could trigger
false block integrity errors, as page could be modified
again when under writeback, the integrity checksum does
not match the new data any more.

Upstream has a pending patch
https://lore.kernel.org/linux-mm/20231025141020.192413-1-hch@lst.de/
which works for RHEL 9 kernels.

For RHEL 8 kernels the changes for bdev made it difficult
to backport, a different patch is used to check and wait
for bdev stable_pages.

Change-Id: Ie088abf29f40b294c31f993bcfad56d6081a3fce
Test-Parameters: trivial
Signed-off-by: Li Dongyang <dongyangli@ddn.com>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/52922
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/kernel_patches/patches/add-and-use-a-per-mapping-stable-writes-flag-rhel9.patch [new file with mode: 0644]
lustre/kernel_patches/patches/mm-wait_for_stable_page-should-check-for-bdev-rhel8.6.patch [new file with mode: 0644]
lustre/kernel_patches/series/4.18-rhel8.6.series
lustre/kernel_patches/series/4.18-rhel8.7.series
lustre/kernel_patches/series/4.18-rhel8.8.series
lustre/kernel_patches/series/4.18-rhel8.9.series
lustre/kernel_patches/series/5.14-rhel9.1.series
lustre/kernel_patches/series/5.14-rhel9.2.series
lustre/kernel_patches/series/5.14-rhel9.3.series