Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b6ef944a authored by Bowgo Tsai's avatar Bowgo Tsai Committed by android-build-merger
Browse files

Merge "init: fix first stage mount failure due to /dev/device-mapper not...

Merge "init: fix first stage mount failure due to /dev/device-mapper not found" am: 0447a3e5 am: ad7c7fe1 am: fd13c701
am: ec0d2ce6

Change-Id: Id5d27476aee25c6019adb4f2ccee9dee580da497
parents 4ef89a92 ec0d2ce6
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -143,8 +143,11 @@ bool FirstStageMount::InitDevices() {
    if (!GetRequiredDevices(&devices_partition_names, &need_dm_verity)) return false;

    if (need_dm_verity) {
        device_init("/sys/devices/virtual/misc/device-mapper",
                    [&](uevent* uevent) -> coldboot_action_t { return COLDBOOT_STOP; });
        const std::string dm_path = "/devices/virtual/misc/device-mapper";
        device_init(("/sys" + dm_path).c_str(), [&dm_path](uevent* uevent) -> coldboot_action_t {
            if (uevent->path == dm_path) return COLDBOOT_STOP;
            return COLDBOOT_CONTINUE;  // dm_path not found, continue to find it.
        });
    }

    bool success = false;