linux/fs/crypto
Eric Biggers 03569f2fb8 fscrypt: introduce fscrypt_encrypt_block_inplace()
fscrypt_encrypt_page() behaves very differently depending on whether the
filesystem set FS_CFLG_OWN_PAGES in its fscrypt_operations.  This makes
the function difficult to understand and document.  It also makes it so
that all callers have to provide inode and lblk_num, when fscrypt could
determine these itself for pagecache pages.

Therefore, move the FS_CFLG_OWN_PAGES behavior into a new function
fscrypt_encrypt_block_inplace().

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

Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
2019-05-28 10:27:52 -07:00
..
bio.c fscrypt: rename fscrypt_do_page_crypto() to fscrypt_crypt_block() 2019-05-28 10:27:52 -07:00
crypto.c fscrypt: introduce fscrypt_encrypt_block_inplace() 2019-05-28 10:27:52 -07:00
fname.c fscrypt: fix race where ->lookup() marks plaintext dentry as ciphertext 2019-04-17 10:07:51 -04:00
fscrypt_private.h fscrypt: rename fscrypt_do_page_crypto() to fscrypt_crypt_block() 2019-05-28 10:27:52 -07:00
hooks.c treewide: Add SPDX license identifier for missed files 2019-05-21 10:50:45 +02:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
keyinfo.c Clean up fscrypt's dcache revalidation support, and other 2019-05-07 21:28:04 -07:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
policy.c fscrypt: use READ_ONCE() to access ->i_crypt_info 2019-04-16 18:57:09 -04:00