diff options
| author | Wei-Ning Huang <wnhuang@google.com> | 2017-08-08 17:26:04 +0800 |
|---|---|---|
| committer | ChromeOS Commit Bot <chromeos-commit-bot@chromium.org> | 2017-08-10 02:55:09 +0000 |
| commit | 3423014d00704543bb428e2ef29c8b6b66325d0f (patch) | |
| tree | dd58db984cf5a80d70e643ac62555d3cc33c4793 /util/ectool.c | |
| parent | 3e6c71ea2740a4a1c4c156e43e4fc81a2587ceb5 (diff) | |
| download | chrome-ec-release-R61-9765.B.tar.gz | |
ectool: do not try other communication methods for none cros_ec devicesstabilize-9765.76.Bstabilize-9765.65.Bstabilize-9765.39.Brelease-R61-9765.B
There are none cros_ec devices running EC codebase connected to
chromebook, which can be accessed by ectool with
`cros_ec --name=SOME_DEV ...`.
In the case when SOME_DEV is not found, do not fallback to other
communication methods such as LPC or I2C, since ectool will instead get
the reply of real cros_ec device.
BRANCH=none
BUG=b:64468324
TEST=on poppy, `ectool --name=cros_tp version` should show:
`Unable to establish host communication
Couldn't find EC`
Change-Id: I2ac232122e0f928703f7607da365d5c1dc6f7194
Signed-off-by: Wei-Ning Huang <wnhuang@google.com>
Reviewed-on: https://chromium-review.googlesource.com/604977
Commit-Ready: Wei-Ning Huang <wnhuang@chromium.org>
Tested-by: Wei-Ning Huang <wnhuang@chromium.org>
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
(cherry picked from commit 25d281a42bd1e3cbf997e658ff9ae784bbecea20)
Reviewed-on: https://chromium-review.googlesource.com/609620
Reviewed-by: Wei-Ning Huang <wnhuang@chromium.org>
Commit-Queue: Wei-Ning Huang <wnhuang@chromium.org>
Diffstat (limited to 'util/ectool.c')
| -rw-r--r-- | util/ectool.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/util/ectool.c b/util/ectool.c index e843fc7308..7b70ab84d6 100644 --- a/util/ectool.c +++ b/util/ectool.c @@ -18,6 +18,7 @@ #include "battery.h" #include "comm-host.h" #include "compile_time_macros.h" +#include "cros_ec_dev.h" #include "ec_panicinfo.h" #include "ec_flash.h" #include "ectool.h" @@ -7330,7 +7331,7 @@ int main(int argc, char *argv[]) const struct command *cmd; int dev = 0; int interfaces = COMM_ALL; - char device_name[40] = "cros_ec"; + char device_name[40] = CROS_EC_DEV_NAME; int rv = 1; int parse_error = 0; char *e; |
