FSCRYPT Adding Direct I/O Support For Encrypted Files In Linux 5.18

Written by Michael Larabel in Linux Storage on 21 March 2022 at 05:28 AM EDT. 2 Comments
It's been a while since having any shiny new features to talk about for FSCRYPT, the Linux kernel's file-system encryption framework that is used by the likes of EXT4 and F2FS. With Linux 5.18 that changes with FSCRYPT adding direct I/O support.

Google's Eric Biggers sent in the FSCRYPT feature pull this morning for the newly-started Linux 5.18 merge window. The big feature there is adding support for direct I/O on encrypted files, which works when blk-crypto is activated for inline encryption handling of the encrypted file contents.

Direct I/O to this point hadn't been supported with FSCRYPT file-system encryption while now it can be but with fallback support to buffered I/O in the event of issues. The "inlinecrypt" mount option must be in use and the system having hardware inline encryption or otherwise have the fallback inline encryption mode enabled.

This direct I/O support with FSCRYPT has been successfully tested with the EXT4 and F2FS file-systems under the above-mentioned criteria.

More details via the FSCRYPT pull request for Linux 5.18.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week