Whamcloud - gitweb
AOSP: ANDROID: mke2fs: Support encrypt+casefold
authorDaniel Rosenberg <drosen@google.com>
Thu, 11 Jun 2020 04:22:05 +0000 (21:22 -0700)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 28 Jan 2021 04:48:46 +0000 (23:48 -0500)
In preparation for upcoming kernel changes that will make the kernel
support both encryption and casefolding at the same time, allow mke2fs
to enable both features at the same time.

Signed-off-by: Daniel Rosenberg <drosen@google.com>
Google-Bug-Id: 138322712
Test: Create fs with casefold and encryption enabled via mke2fs
Change-Id: I4e2350e43e21cffb3d972310cd74df1e662bf87e
From AOSP commit: f8fc427df385260f3424e1e9d5485c8640606920

misc/mke2fs.c

index edab068..8cdb007 100644 (file)
@@ -2480,15 +2480,6 @@ profile_error:
                }
        }
 
-       if (ext2fs_has_feature_casefold(&fs_param) &&
-           ext2fs_has_feature_encrypt(&fs_param)) {
-               com_err(program_name, 0, "%s",
-                       _("The encrypt and casefold features are not "
-                         "compatible.\nThey can not be both enabled "
-                         "simultaneously.\n"));
-                     exit (1);
-       }
-
        /* Don't allow user to set both metadata_csum and uninit_bg bits. */
        if (ext2fs_has_feature_metadata_csum(&fs_param) &&
            ext2fs_has_feature_gdt_csum(&fs_param))