Loading
fs_mgr: overlayfs: CreateDynamicScratch for *partition_exists
Commit 69def12f ("overlayfs: Refactor how the scratch device is deduced, again.") introduced a regression which dropped a call to dm.GetDmDevicePathByName. The call was formerly done to check if a partition existed and shortcuted the logic. As a result when the partition exists and is already instantiated, CreateDynamicScratch function fails to fill out *scratch_device return value. The bandaid is to call GetBootScratchDevice() to leverage its own GetDmDevicePathByName call to fill out if it is detected as an empty value in CreateDynamicScratch, only called under this condition. Signed-off-by:Mark Salyzyn <salyzyn@google.com> Test: adb-remount-test.sh Bug: 148881519 Change-Id: I40464e8dd17d25a292a275d0b9df5f9519b794fb