diff options
author | Craig Hesling <hesling@chromium.org> | 2022-10-06 21:35:35 -0400 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-10-07 17:43:42 +0000 |
commit | 7c5f4b9021be26ff63fed71bae466104b00fde2f (patch) | |
tree | 4631025c75f79f4484cda7dd4f36c91a1e060f76 | |
parent | dbf15673583860a734eb7373a0c1de414781cd49 (diff) | |
download | chrome-ec-7c5f4b9021be26ff63fed71bae466104b00fde2f.tar.gz |
util: Change flash_ec file check to exists check
This allows passing a pipe file as the image, which could be used to
invoke flash_ec thorough ssh and a pipe for the image file.
BRANCH=none
BUG=b:176500425
TEST=ssh DUT -- flash_ec --board=bloonchipper "--image=<(cat)" <.../ec.bin
Signed-off-by: Craig Hesling <hesling@chromium.org>
Change-Id: I509037626e8c7299613ebdaf5391edfa0cf6a6fa
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3937047
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
-rwxr-xr-x | util/flash_ec | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util/flash_ec b/util/flash_ec index 9c13e045f1..8419c2e7a0 100755 --- a/util/flash_ec +++ b/util/flash_ec @@ -731,7 +731,7 @@ fi function ec_image() { # No image specified on the command line, try default ones if [[ -n "${FLAGS_image}" ]] ; then - if [ -f "${FLAGS_image}" ] || \ + if [ -e "${FLAGS_image}" ] || \ [ "${FLAGS_image}" == "-" ]; then echo "${FLAGS_image}" return |