Skip to content

Commit 880253e

Browse files
Satya Tangiralaebiggers
authored andcommitted
fscrypt: document inline encryption support
Update the fscrypt documentation file for inline encryption support. Signed-off-by: Satya Tangirala <[email protected]> Reviewed-by: Eric Biggers <[email protected]> Reviewed-by: Jaegeuk Kim <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Eric Biggers <[email protected]>
1 parent ab673b9 commit 880253e

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

Documentation/filesystems/fscrypt.rst

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1204,6 +1204,18 @@ buffer. Some filesystems, such as UBIFS, already use temporary
12041204
buffers regardless of encryption. Other filesystems, such as ext4 and
12051205
F2FS, have to allocate bounce pages specially for encryption.
12061206

1207+
Fscrypt is also able to use inline encryption hardware instead of the
1208+
kernel crypto API for en/decryption of file contents. When possible,
1209+
and if directed to do so (by specifying the 'inlinecrypt' mount option
1210+
for an ext4/F2FS filesystem), it adds encryption contexts to bios and
1211+
uses blk-crypto to perform the en/decryption instead of making use of
1212+
the above read/write path changes. Of course, even if directed to
1213+
make use of inline encryption, fscrypt will only be able to do so if
1214+
either hardware inline encryption support is available for the
1215+
selected encryption algorithm or CONFIG_BLK_INLINE_ENCRYPTION_FALLBACK
1216+
is selected. If neither is the case, fscrypt will fall back to using
1217+
the above mentioned read/write path changes for en/decryption.
1218+
12071219
Filename hashing and encoding
12081220
-----------------------------
12091221

@@ -1250,7 +1262,9 @@ Tests
12501262

12511263
To test fscrypt, use xfstests, which is Linux's de facto standard
12521264
filesystem test suite. First, run all the tests in the "encrypt"
1253-
group on the relevant filesystem(s). For example, to test ext4 and
1265+
group on the relevant filesystem(s). One can also run the tests
1266+
with the 'inlinecrypt' mount option to test the implementation for
1267+
inline encryption support. For example, to test ext4 and
12541268
f2fs encryption using `kvm-xfstests
12551269
<https://github.com/tytso/xfstests-bld/blob/master/Documentation/kvm-quickstart.md>`_::
12561270

0 commit comments

Comments
 (0)