diff options
-rw-r--r-- | common/system_common.c | 12 | ||||
-rw-r--r-- | include/ec_commands.h | 3 | ||||
-rw-r--r-- | util/ectool.c | 2 |
3 files changed, 9 insertions, 8 deletions
diff --git a/common/system_common.c b/common/system_common.c index 847e808fd2..d3f4f3f6fd 100644 --- a/common/system_common.c +++ b/common/system_common.c @@ -865,12 +865,14 @@ int host_command_reboot(struct host_cmd_handler_args *args) return EC_RES_SUCCESS; } - /* TODO: (crosbug.com/p/9040) handle EC_REBOOT_FLAG_POWER_ON */ - #ifdef CONFIG_TASK_HOSTCMD - /* Clean busy bits on host */ - args->result = EC_RES_SUCCESS; - host_send_response(args); + if (p.cmd == EC_REBOOT_JUMP_RO || + p.cmd == EC_REBOOT_JUMP_RW || + p.cmd == EC_REBOOT_COLD) { + /* Clean busy bits on host for commands that won't return */ + args->result = EC_RES_SUCCESS; + host_send_response(args); + } #endif CPRINTF("[%T Executing host reboot command %d]\n", p.cmd); diff --git a/include/ec_commands.h b/include/ec_commands.h index f30f6a71a4..ac7a06893f 100644 --- a/include/ec_commands.h +++ b/include/ec_commands.h @@ -1047,8 +1047,7 @@ enum ec_reboot_cmd { /* Flags for ec_params_reboot_ec.reboot_flags */ #define EC_REBOOT_FLAG_RESERVED0 (1 << 0) /* Was recovery request */ -#define EC_REBOOT_FLAG_ON_AP_SHUTDOWN (1 << 1) -#define EC_REBOOT_FLAG_POWER_ON (1 << 2) +#define EC_REBOOT_FLAG_ON_AP_SHUTDOWN (1 << 1) /* Reboot after AP shutdown */ struct ec_params_reboot_ec { uint8_t cmd; /* enum ec_reboot_cmd */ diff --git a/util/ectool.c b/util/ectool.c index 7ddaa07c06..f281fd62ac 100644 --- a/util/ectool.c +++ b/util/ectool.c @@ -110,7 +110,7 @@ const char help_str[] = " Set keyboard backlight in percent\n" " readtest <patternoffset> <size>\n" " Reads a pattern from the EC via LPC\n" - " reboot_ec <RO|A|disable-jump> [at-shutdown]\n" + " reboot_ec <RO|RW|disable-jump> [at-shutdown]\n" " Reboot EC to RO or RW\n" " rtcget\n" " Print real-time clock\n" |