Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 24ee3133 authored by Daniel Rosenberg's avatar Daniel Rosenberg Committed by Greg Kroah-Hartman
Browse files

BACKPORT: ext4: Only advertise encrypted_casefold when encryption and unicode are enabled



[ Upstream commit e71f99f2dfb45f4e7203a0732e85f71ef1d04dab ]

Encrypted casefolding is only supported when both encryption and
casefolding are both enabled in the config.

Fixes: 471fbbea7ff7 ("ext4: handle casefolding with encryption")
Cc: stable@vger.kernel.org # 5.13+
Signed-off-by: default avatarDaniel Rosenberg <drosen@google.com>
Link: https://lore.kernel.org/r/20210603094849.314342-1-drosen@google.com


Signed-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
Change-Id: I4655b3aab60006ea03fb3454a0a833634546373b
parent 4adf8282
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -250,7 +250,9 @@ EXT4_ATTR_FEATURE(casefold);
EXT4_ATTR_FEATURE(verity);
#endif
EXT4_ATTR_FEATURE(metadata_csum_seed);
#if defined(CONFIG_UNICODE) && defined(CONFIG_FS_ENCRYPTION)
EXT4_ATTR_FEATURE(encrypted_casefold);
#endif

static struct attribute *ext4_feat_attrs[] = {
	ATTR_LIST(lazy_itable_init),
@@ -267,7 +269,9 @@ static struct attribute *ext4_feat_attrs[] = {
	ATTR_LIST(verity),
#endif
	ATTR_LIST(metadata_csum_seed),
#if defined(CONFIG_UNICODE) && defined(CONFIG_FS_ENCRYPTION)
	ATTR_LIST(encrypted_casefold),
#endif
	NULL,
};
ATTRIBUTE_GROUPS(ext4_feat);