fs_mgr: remount: pull root device from fstab
For devices that do not support overlayfs that are system as root, need to pull /dev/root device from / mount point in fstab. Test: adb-remount-test.sh Bug: 126256072 Change-Id: I198c0e8c60770508737318afde95db2966294ff5
This commit is contained in:
parent
448fc9783c
commit
3babd8488b
|
@ -346,11 +346,15 @@ int main(int argc, char* argv[]) {
|
|||
break;
|
||||
}
|
||||
if ((mount_point == "/") && (rentry.mount_point == "/system")) {
|
||||
if (blk_device != "/dev/root") blk_device = rentry.blk_device;
|
||||
blk_device = rentry.blk_device;
|
||||
mount_point = "/system";
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (blk_device == "/dev/root") {
|
||||
auto from_fstab = GetEntryForMountPoint(&fstab, mount_point);
|
||||
if (from_fstab) blk_device = from_fstab->blk_device;
|
||||
}
|
||||
fs_mgr_set_blk_ro(blk_device, false);
|
||||
|
||||
// Now remount!
|
||||
|
|
Loading…
Reference in New Issue