Re: [PATCH 0/7] ecryptfs: remove the remaining struct page usage
From: Tal Zussman
Date: Thu Oct 22 2026 - 12:33:04 EST
On 10/14/26 9:35 PM, Tal Zussman wrote:
> Convert the page cache side of the encryption path to folios, and use
> plain kernel memory for the buffers that were only pages because of the
> old interfaces: the ciphertext block, the header buffer from
> ecryptfs_get_zeroed_pages(), and the scatterlists built by
> virt_to_scatterlist(). Also make a shrinking truncate zero the tail of
> the last folio in place, as other filesystems do, instead of copying
> from the zero page through the write path. After this, fs/ecryptfs has
> no struct page usage left.
>
> Ran cleanly with fsx and fsstress on ecryptfs over ext4 in the default,
> xattr, and passthrough mount options.
>
> ---
> Tal Zussman (7):
> ecryptfs: remove struct ecryptfs_page_crypt_context
> ecryptfs: use a folio and a buffer in crypt_extent()
> ecryptfs: use kzalloc() for the header buffer
> ecryptfs: use sg_init_one() instead of virt_to_scatterlist()
> ecryptfs: zero the tail of the last folio in place on truncate
> ecryptfs: rename functions to refer to folios
> ecryptfs: refer to folios in comments and printk strings
>
Sashiko found some issues with patches 4 and 5. I'll send v2 with fixes
soon.
Thanks,
Tal