]> asedeno.scripts.mit.edu Git - linux.git/commit
fscrypt: support decrypting multiple filesystem blocks per page
authorEric Biggers <ebiggers@google.com>
Mon, 20 May 2019 16:29:47 +0000 (09:29 -0700)
committerEric Biggers <ebiggers@google.com>
Tue, 28 May 2019 17:27:53 +0000 (10:27 -0700)
commitaa8bc1ac6ef32a332671ca25e06cfd277a3839a5
tree40a7109717078adacb8bed18199f35fb706f36f3
parent41adbcb7267b0060682576d523956160b5c617bd
fscrypt: support decrypting multiple filesystem blocks per page

Rename fscrypt_decrypt_page() to fscrypt_decrypt_pagecache_blocks() and
redefine its behavior to decrypt all filesystem blocks in the given
region of the given page, rather than assuming that the region consists
of just one filesystem block.  Also remove the 'inode' and 'lblk_num'
parameters, since they can be retrieved from the page as it's already
assumed to be a pagecache page.

This is in preparation for allowing encryption on ext4 filesystems with
blocksize != PAGE_SIZE.

This is based on work by Chandan Rajendra.

Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
fs/crypto/bio.c
fs/crypto/crypto.c
fs/ext4/inode.c
include/linux/fscrypt.h