Revert "dragonboards: fstab: Mount /data as F2FS partition"
This reverts commit 6d08753ba81a82e8ca22474bd628bd563c069199.
Broke 'adb sync' and make the device unusable after reboot.
On reboot I see:
[ 18.478644][ T325] fsck.f2fs: Info: superblock encrypt level = 0, salt = 00000000000000000000000000000000
[ 18.478646][ T325] fsck.f2fs: Info: fs errors: invalid_blkaddr
[ 18.528319][ T325] fsck.f2fs: Info: Segments per section = 1
[ 18.534121][ T325] fsck.f2fs: Info: Sections per zone = 1
[ 18.539666][ T325] fsck.f2fs: Info: total FS sectors = 5242880 (20480 MB)
[ 18.546606][ T325] fsck.f2fs: Info: CKPT version = 4412b579
[ 18.552312][ T325] fsck.f2fs: Info: version timestamp cur: 99, prev: 0
[ 18.558992][ T325] fsck.f2fs: [update_superblock: 884] Info: Done to update superblock
[ 18.719832][ T325] fsck.f2fs: Info: Corrupted valid nat_bits in checkpoint
[ 18.756808][ T325] fsck.f2fs: Info: Write valid nat_bits in checkpoint
[ 18.787849][ T325] fsck.f2fs: Info: checkpoint state = c6 : nat_bits crc compacted_summary orphan_inodes sudden-power-off
[ 18.871592][ T325] fsck.f2fs: [FSCK] Check node 340 / 3404 (10.00%)
[ 18.878081][ T325] fsck.f2fs: [ASSERT] (is_valid_ssa_data_blk: 341) --> Set data summary 0x3 -> [0x19f] [0x0] [0x0]
[ 18.888821][ T325] fsck.f2fs: [ASSERT] (is_valid_ssa_data_blk: 341) --> Set data summary 0x3 -> [0x19f] [0x0] [0x1]
[ 18.899518][ T325] fsck.f2fs: [ASSERT] (is_valid_ssa_data_blk: 341) --> Set data summary 0x3 -> [0x19f] [0x0] [0x2]
[ 18.910208][ T325] fsck.f2fs: [ASSERT] (is_valid_ssa_data_blk: 341) --> Set data summary 0x3 -> [0x19f] [0x0] [0x3]
[ 18.920928][ T325] fsck.f2fs: [ASSERT] (is_valid_ssa_data_blk: 341) --> Set data summary 0x3 -> [0x19f] [0x0] [0x4]
[ 18.931662][ T325] fsck.f2fs: [ASSERT] (is_valid_ssa_data_blk: 341) --> Set data summary 0x3 -> [0x19f] [0x0] [0x5]
... ....
I need to take a look at fstab mount options again.
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Change-Id: I790ce85cf05cb20df82f7398197b076c1af50022
diff --git a/BoardConfigCommon.mk b/BoardConfigCommon.mk
index ac375bc..08c5c57 100644
--- a/BoardConfigCommon.mk
+++ b/BoardConfigCommon.mk
@@ -19,8 +19,7 @@
TARGET_NO_RECOVERY := true
BOARD_SYSTEMIMAGE_FILE_SYSTEM_TYPE := erofs
-TARGET_USERIMAGES_USE_F2FS := true
-BOARD_USERDATAIMAGE_FILE_SYSTEM_TYPE := f2fs
+TARGET_USERIMAGES_USE_EXT4 := true
TARGET_COPY_OUT_VENDOR := vendor
BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE := erofs
TARGET_COPY_OUT_SYSTEM_EXT := system_ext
diff --git a/device-common.mk b/device-common.mk
index b530c0d..a197f86 100644
--- a/device-common.mk
+++ b/device-common.mk
@@ -68,11 +68,6 @@
system_ext \
vendor
-# Tools to build f2fs images
-PRODUCT_HOST_PACKAGES := \
- fsck.f2fs \
- make_f2fs
-
ifeq ($(TARGET_SDCARD_BOOT), true)
ifneq ($(filter 5.4 5.10 5.15, $(TARGET_KERNEL_USE)),)
PRODUCT_COPY_FILES += \
diff --git a/fstab.common b/fstab.common
index 6772e38..c618b7a 100644
--- a/fstab.common
+++ b/fstab.common
@@ -1,5 +1,5 @@
system /system erofs ro wait,logical,first_stage_mount,slotselect
-/dev/block/platform/soc@0/1d84000.ufshc/by-name/userdata /data f2fs nodev,noatime,nosuid,inlinecrypt,reserve_root=32768 latemount,wait,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,keydirectory=/metadata/vold/metadata_encryption,quota,check,fscompress,checkpoint=fs
+/dev/block/platform/soc@0/1d84000.ufshc/by-name/userdata /data ext4 discard,noatime,noauto_da_alloc,data=ordered,user_xattr,barrier=1,inlinecrypt latemount,wait,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,keydirectory=/metadata/vold/metadata_encryption,quota
/dev/block/platform/soc@0/1d84000.ufshc/by-name/metadata /metadata ext4 noatime,nosuid,nodev,discard wait,formattable,first_stage_mount,check
/dev/block/platform/soc@0/1d84000.ufshc/by-name/misc /misc emmc defaults defaults
/devices/platform/soc@0/8804000.sdhci/mmc_host/mmc* auto auto defaults voldmanaged=sdcard1:auto
diff --git a/shared/utils/sdcard-boot/fstab.mmc b/shared/utils/sdcard-boot/fstab.mmc
index 1f689e8..387a0cd 100644
--- a/shared/utils/sdcard-boot/fstab.mmc
+++ b/shared/utils/sdcard-boot/fstab.mmc
@@ -1,5 +1,5 @@
system /system erofs ro wait,logical,first_stage_mount,slotselect
-/dev/block/platform/soc@0/8804000.mmc/by-name/userdata /data f2fs nodev,noatime,nosuid,inlinecrypt,reserve_root=32768 latemount,wait,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,keydirectory=/metadata/vold/metadata_encryption,quota,check,fscompress,checkpoint=fs
+/dev/block/platform/soc@0/8804000.mmc/by-name/userdata /data ext4 discard,noatime,noauto_da_alloc,data=ordered,user_xattr,barrier=1,inlinecrypt latemount,wait,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,keydirectory=/metadata/vold/metadata_encryption,quota
/dev/block/platform/soc@0/8804000.mmc/by-name/metadata /metadata ext4 noatime,nosuid,nodev,discard wait,formattable,first_stage_mount,check
/dev/block/platform/soc@0/8804000.mmc/by-name/misc /misc emmc defaults defaults
/devices/platform/soc@0/a8f8800.usb/*/usb* auto auto defaults voldmanaged=usb1:auto
diff --git a/shared/utils/sdcard-boot/fstab.sdhci b/shared/utils/sdcard-boot/fstab.sdhci
index 746f516..c385ba6 100644
--- a/shared/utils/sdcard-boot/fstab.sdhci
+++ b/shared/utils/sdcard-boot/fstab.sdhci
@@ -1,5 +1,5 @@
system /system erofs ro wait,logical,first_stage_mount,slotselect
-/dev/block/platform/soc@0/8804000.sdhci/by-name/userdata /data f2fs nodev,noatime,nosuid,inlinecrypt,reserve_root=32768 latemount,wait,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,keydirectory=/metadata/vold/metadata_encryption,quota,check,fscompress,checkpoint=fs
+/dev/block/platform/soc@0/8804000.sdhci/by-name/userdata /data ext4 discard,noatime,noauto_da_alloc,data=ordered,user_xattr,barrier=1,inlinecrypt latemount,wait,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,keydirectory=/metadata/vold/metadata_encryption,quota
/dev/block/platform/soc@0/8804000.sdhci/by-name/metadata /metadata ext4 noatime,nosuid,nodev,discard wait,formattable,first_stage_mount,check
/dev/block/platform/soc@0/8804000.sdhci/by-name/misc /misc emmc defaults defaults
/devices/platform/soc@0/a8f8800.usb/*/usb* auto auto defaults voldmanaged=usb1:auto