From 5cb3f501a975da1db229e52eff40a43feb6dc07f Mon Sep 17 00:00:00 2001 From: Patrick Farrell Date: Tue, 30 Jan 2024 16:07:59 -0500 Subject: [PATCH] LU-17422 osc: Clear PageChecked on bounce pages When we're finalizing a bounce page, we must clear PageChecked. Otherwise, if it's a page pool page, it will be reused without the full wipe the kernel gives it, and we will see PageChecked on pages which are not actually from encryption and will handle them incorrectly. Lustre-Change: https://review.whamcloud.com/53865/ Lustre-Commit: TBD (from 5582abc557a8d7188bbb6fb2bc38585338f660b4) Signed-off-by: Patrick Farrell Change-Id: I8b319e7ba55dd883d74db79a19bf93b6f125616a Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/53866 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Sebastien Buisson Reviewed-by: Andreas Dilger --- lustre/osc/osc_request.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lustre/osc/osc_request.c b/lustre/osc/osc_request.c index 9629da3..ccd60da 100644 --- a/lustre/osc/osc_request.c +++ b/lustre/osc/osc_request.c @@ -1444,6 +1444,7 @@ static inline void osc_finalize_bounce_page(struct page **pagep) { struct page *page = *pagep; + ClearPageChecked(page); /* PagePrivate2 was set in osc_encrypt_pagecache_blocks * to indicate the cipher page was allocated by ourselves. * So we must not free it via llcrypt. -- 1.8.3.1