From c11f8e55b1a088a6c7c1709d76c1d986f3ddfa50 Mon Sep 17 00:00:00 2001 From: Mark Salyzyn Date: Tue, 22 Jan 2019 08:54:56 -0800 Subject: [PATCH] fs_mgr: overlayfs: erofs is in staging erofs is in upstream staging and in 4.19, and we see some Android partners considering it as an option instead of squashfs. However, squashfs and erofs filesystems are always 100% full, so we can safely remove the string checking instead and just rely on the statvfs call. We will provide lip-service to our support in comment only. This does _not_ mean we support the decision by our partners to use erofs, as we have not evaluated the performance. Test: adb_remount_test.sh Bug: 109821005 Change-Id: I80ea3a33b9da6684ee95489132bc8a88b2310ac8 --- fs_mgr/fs_mgr_overlayfs.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs_mgr/fs_mgr_overlayfs.cpp b/fs_mgr/fs_mgr_overlayfs.cpp index 0f89467e5..390868311 100644 --- a/fs_mgr/fs_mgr_overlayfs.cpp +++ b/fs_mgr/fs_mgr_overlayfs.cpp @@ -137,9 +137,9 @@ bool fs_mgr_filesystem_has_space(const std::string& mount_point) { bool fs_mgr_overlayfs_enabled(FstabEntry* entry) { // readonly filesystem, can not be mount -o remount,rw - // if squashfs or if free space is (near) zero making such a remount + // for squashfs, erofs or if free space is (near) zero making such a remount // virtually useless, or if there are shared blocks that prevent remount,rw - if ("squashfs" == entry->fs_type || !fs_mgr_filesystem_has_space(entry->mount_point)) { + if (!fs_mgr_filesystem_has_space(entry->mount_point)) { return true; } if (entry->fs_mgr_flags.logical) {