Whamcloud - gitweb
LU-17422 osc: Clear PageChecked on bounce pages 65/53865/1
authorPatrick Farrell <pfarrell@whamcloud.com>
Tue, 30 Jan 2024 20:15:38 +0000 (15:15 -0500)
committerPatrick Farrell <pfarrell@whamcloud.com>
Tue, 30 Jan 2024 20:17:31 +0000 (15:17 -0500)
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.

Signed-off-by: Patrick Farrell <pfarrell@whamcloud.com>
Change-Id: I8b319e7ba55dd883d74db79a19bf93b6f125616a

lustre/osc/osc_request.c

index dec57a5..7224508 100644 (file)
@@ -1442,6 +1442,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.