cryptfs: remove reference to legacy make_ext4fs

Use upstream mke2fs tool to format ext4 filesystem.

Bug: 64395169
Change-Id: I383510f25a7c0935ddb280a14ef31fcbd143cba1
gugelfrei
Jin Qian 7 years ago
parent ea90d0504b
commit b678d7c3f7

@ -85,14 +85,7 @@ vold_cflags := -Werror -Wall -Wno-missing-field-initializers -Wno-unused-variabl
required_modules :=
ifeq ($(TARGET_USERIMAGES_USE_EXT4), true)
ifeq ($(TARGET_USES_MKE2FS), true)
vold_cflags += -DTARGET_USES_MKE2FS
required_modules += mke2fs
else
# Adoptable storage has fully moved to mke2fs, so we need both tools
required_modules += mke2fs
required_modules += make_ext4fs
endif
required_modules += mke2fs
endif
include $(CLEAR_VARS)

@ -38,7 +38,6 @@
#include <openssl/evp.h>
#include <openssl/sha.h>
#include <errno.h>
#include <ext4_utils/ext4.h>
#include <ext4_utils/ext4_utils.h>
#include <linux/kdev_t.h>
#include <fs_mgr.h>
@ -1913,7 +1912,6 @@ static int cryptfs_enable_wipe(char *crypto_blkdev, off64_t size, int type)
int rc = -1;
if (type == EXT4_FS) {
#ifdef TARGET_USES_MKE2FS
args[0] = "/system/bin/mke2fs";
args[1] = "-M";
args[2] = "/data";
@ -1925,16 +1923,6 @@ static int cryptfs_enable_wipe(char *crypto_blkdev, off64_t size, int type)
snprintf(size_str, sizeof(size_str), "%" PRId64, size / (4096 / 512));
args[8] = size_str;
num_args = 9;
#else
args[0] = "/system/bin/make_ext4fs";
args[1] = "-a";
args[2] = "/data";
args[3] = "-l";
snprintf(size_str, sizeof(size_str), "%" PRId64, size * 512);
args[4] = size_str;
args[5] = crypto_blkdev;
num_args = 6;
#endif
SLOGI("Making empty filesystem with command %s %s %s %s %s %s\n",
args[0], args[1], args[2], args[3], args[4], args[5]);
} else if (type == F2FS_FS) {

Loading…
Cancel
Save