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

Commit 1f666a6b authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge changes from topic "b/63736262"

* changes:
  adb: reboot: last boot command default
  bootstat: introduce sys.boot.reason
parents 7176951b 277eca13
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -150,6 +150,7 @@ static bool reboot_service_impl(int fd, const char* arg) {

    sync();

    if (!reboot_arg || !reboot_arg[0]) reboot_arg = "adb";
    std::string reboot_string = android::base::StringPrintf("reboot,%s", reboot_arg);
    if (!android::base::SetProperty(ANDROID_RB_PROPERTY, reboot_string)) {
        WriteFdFmt(fd, "reboot (%s) failed\n", reboot_string.c_str());
+1 −0
Original line number Diff line number Diff line
@@ -63,6 +63,7 @@ cc_binary {
    name: "bootstat",
    defaults: ["bootstat_defaults"],
    static_libs: ["libbootstat"],
    shared_libs: ["liblogcat"],
    init_rc: ["bootstat.rc"],
    srcs: ["bootstat.cpp"],
}
+721 −0

File added.

Preview size limit exceeded, changes collapsed.

+371 −2

File changed.

Preview size limit exceeded, changes collapsed.

+4 −0
Original line number Diff line number Diff line
# This file is the LOCAL_INIT_RC file for the bootstat command.

# mirror bootloader boot reason to system boot reason
on property:ro.boot.bootreason=*
    setprop sys.boot.reason ${ro.boot.bootreason}

on post-fs-data
    mkdir /data/misc/bootstat 0700 system log
    # To deal with ota transition resulting from a change in DAC from
Loading