diff options
author | xunchang <xunchang@google.com> | 2019-04-05 16:16:07 -0700 |
---|---|---|
committer | xunchang <xunchang@google.com> | 2019-04-11 14:23:53 -0700 |
commit | 34690ced91e22f5d9b5dd19c33b11c8e0b4bafa0 (patch) | |
tree | fc51bb568fdb244bd4cc7687a665230a1f3a9fa4 /recovery_main.cpp | |
parent | 38d5e6087416af0600fda4992a7dfb2a18aec45a (diff) |
Add socket communication between recovery and minadbd
This cl adds a socket pair to support the communication between recovery
and minadbd. Therefore, minadbd will be able to issue multiple commands
to recovery and get back the status of each command.
This cl also switches the adb sideload from the recovery menu to use
this protocol; and moves minadbd to a separate binary.
Bug: 130166585
Test: sideload a package
Change-Id: I80d36d5c4e6fe1ae3ea23640907bc50c0dc0d482
Diffstat (limited to 'recovery_main.cpp')
-rw-r--r-- | recovery_main.cpp | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/recovery_main.cpp b/recovery_main.cpp index b41368d7..8b4ad5a3 100644 --- a/recovery_main.cpp +++ b/recovery_main.cpp @@ -51,7 +51,6 @@ #include "common.h" #include "fastboot/fastboot.h" #include "logging.h" -#include "minadbd/minadbd.h" #include "otautil/paths.h" #include "otautil/roots.h" #include "otautil/sysutil.h" @@ -322,16 +321,6 @@ int main(int argc, char** argv) { // Take action to refresh pmsg contents __android_log_pmsg_file_read(LOG_ID_SYSTEM, ANDROID_LOG_INFO, filter, logrotate, &do_rotate); - // If this binary is started with the single argument "--adbd", instead of being the normal - // recovery binary, it turns into kind of a stripped-down version of adbd that only supports the - // 'sideload' command. Note this must be a real argument, not anything in the command file or - // bootloader control block; the only way recovery should be run with this argument is when it - // starts a copy of itself from the apply_from_adb() function. - if (argc == 2 && strcmp(argv[1], "--adbd") == 0) { - minadbd_main(); - return 0; - } - time_t start = time(nullptr); // redirect_stdio should be called only in non-sideload mode. Otherwise we may have two logger |