]> asedeno.scripts.mit.edu Git - linux.git/commit
ext4: encrypt only up to last block in ext4_bio_write_page()
authorEric Biggers <ebiggers@google.com>
Mon, 20 May 2019 16:29:52 +0000 (09:29 -0700)
committerEric Biggers <ebiggers@google.com>
Tue, 28 May 2019 17:27:53 +0000 (10:27 -0700)
commit6e4b73bcd1519d50680d92ba74887c80c4e59140
tree36dcd075033712f765fedf4340713b8f23122803
parentec39a36867440995c9675b2800f5ddaeb51b024e
ext4: encrypt only up to last block in ext4_bio_write_page()

As an optimization, don't encrypt blocks fully beyond i_size, since
those definitely won't need to be written out.  Also add a comment.

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/ext4/page-io.c