summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2015-02-25 18:43:03 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2015-02-25 18:43:04 +0000
commita82f2b259076135017a2665bfbc3344826e9112f (patch)
tree88da6c964d81633cf347c031c236c4a90da209ce
parentd75d6c91d24c071534ed36db85a1e72b33dc5a10 (diff)
parentca85df0662735eaefd512e63eab83caf994be1a6 (diff)
downloadsystem_core-a82f2b259076135017a2665bfbc3344826e9112f.tar.gz
system_core-a82f2b259076135017a2665bfbc3344826e9112f.tar.bz2
system_core-a82f2b259076135017a2665bfbc3344826e9112f.zip
Merge "Support "fastboot reboot bootloader"."
-rw-r--r--fastboot/fastboot.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/fastboot/fastboot.c b/fastboot/fastboot.c
index 959d3ad0f..fc544a66e 100644
--- a/fastboot/fastboot.c
+++ b/fastboot/fastboot.c
@@ -300,7 +300,7 @@ void usage(void)
" flash it\n"
" devices list all connected devices\n"
" continue continue with autoboot\n"
- " reboot reboot device normally\n"
+ " reboot [bootloader] reboot device, optionally into bootloader\n"
" reboot-bootloader reboot device into bootloader\n"
" help show this help message\n"
"\n"
@@ -1153,6 +1153,14 @@ int main(int argc, char **argv)
} else if(!strcmp(*argv, "reboot")) {
wants_reboot = 1;
skip(1);
+ if (argc > 0) {
+ if (!strcmp(*argv, "bootloader")) {
+ wants_reboot = 0;
+ wants_reboot_bootloader = 1;
+ skip(1);
+ }
+ }
+ require(0);
} else if(!strcmp(*argv, "reboot-bootloader")) {
wants_reboot_bootloader = 1;
skip(1);