Thread (12 messages) flat view 12 messages, 2 authors, 2020-07-03

Re: [PATCH v9 0/4] Prepare for upcoming Casefolding/Encryption patches

From: Eric Biggers <ebiggers@kernel.org>
Date: 2020-06-24 05:35:06
Also in: linux-ext4, linux-f2fs-devel, linux-fscrypt, linux-fsdevel, lkml

On Tue, Jun 23, 2020 at 09:33:37PM -0700, Daniel Rosenberg wrote:
This lays the ground work for enabling casefolding and encryption at the
same time for ext4 and f2fs. A future set of patches will enable that
functionality. These unify the highly similar dentry_operations that ext4
and f2fs both use for casefolding.
I think this undersells this patchset a bit.  This patchset makes ext4 and f2fs
share the casefolded ->d_compare() and ->d_hash() implementations, which
eliminates duplicated code.  That's a good thing regardless of whether we're
going to add encrypt+casefold support or not.

It also changes the casefolded ->d_hash() implementation to not have to allocate
memory (with GFP_ATOMIC, no less), which was a big problem with the old
implementation as it's unreliable and inefficient.

So yes, this prepares for supporting encrypt+casefold.  But these changes make
sense on their own too as an improvement of the casefold feature.  Except for
the one line of code in needs_casefold() that is specific to encrypt+casefold;
maybe that should be left out for now.

(Side note: I think you could drop linux-doc and linux-mtd from Cc, as this
patchset isn't really relevant to those mailing lists.)

- Eric
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help