3 ms·
> or store the data out-of-line [...] which requires up to 2x writes and because writes to separate sectors aren't atomic, you probably want to add journaling
by Hello71 3y ago
> or store the data out-of-line [...] which requires up to 2x writes
and because writes to separate sectors aren't atomic, you probably want to add journaling or some kind of CoW for crash safety, and oh look now you're actually just writing a filesystem and it's not simpler anymore.
- mike_hock 3y agoNo, you're writing something that happens to resemble a small subset of the functionality of a filesystem. Most importantly, you're not duplicating the effort for every filesystem that you want to support encryption for, and the code can largely remain fixed once mature.
- Tobu 3y agokernel developers are free to factor in common functionality, calling into it library style, without making it into an externally visible layer. IIRC fs encryption and case insensitivity are often done that way, and I think I'd count the page cache and bios as larger library-style components as well (as opposed to the VFS layer which is more in a framework style).