TransformFstabForDsu() skips handling special devices
Don't try to find a scratch partition in the fstab as it is a special devices initialized by fs_mgr_overlayfs during "adb remount". Don't hardcode the string "userdata_gsi", instead use the constant kDsuUserdata defined in libgsi.h. Bug: 165925766 Test: Build pass. Test: Install and boot a DSU. Change-Id: I4eaff9461e87e49704c976ddf2a096642957cf56
This commit is contained in:
parent
f536731e5a
commit
62c75b16d2
|
@ -590,7 +590,7 @@ void TransformFstabForDsu(Fstab* fstab, const std::vector<std::string>& dsu_part
|
|||
FstabEntry userdata;
|
||||
if (FstabEntry* entry = GetEntryForMountPoint(fstab, "/data")) {
|
||||
userdata = *entry;
|
||||
userdata.blk_device = "userdata_gsi";
|
||||
userdata.blk_device = android::gsi::kDsuUserdata;
|
||||
userdata.fs_mgr_flags.logical = true;
|
||||
userdata.fs_mgr_flags.formattable = true;
|
||||
if (!userdata.metadata_key_dir.empty()) {
|
||||
|
@ -610,7 +610,11 @@ void TransformFstabForDsu(Fstab* fstab, const std::vector<std::string>& dsu_part
|
|||
continue;
|
||||
}
|
||||
// userdata has been handled
|
||||
if (StartsWith(partition, "user")) {
|
||||
if (partition == android::gsi::kDsuUserdata) {
|
||||
continue;
|
||||
}
|
||||
// scratch is handled by fs_mgr_overlayfs
|
||||
if (partition == android::gsi::kDsuScratch) {
|
||||
continue;
|
||||
}
|
||||
// dsu_partition_name = corresponding_partition_name + kDsuPostfix
|
||||
|
|
Loading…
Reference in New Issue