summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorShawn Nematbakhsh <shawnn@chromium.org>2017-10-11 23:18:34 -0700
committerchrome-bot <chrome-bot@chromium.org>2017-10-19 12:56:42 -0700
commit7c2c5a9dc3779587f78a7c602cefeb667d210d41 (patch)
treef2b179a1f14cebf2be87553ea56d23da46dfa483 /util
parente7dfbf35a403dfa71bb839c3e722a347447be3f5 (diff)
downloadchrome-ec-7c2c5a9dc3779587f78a7c602cefeb667d210d41.tar.gz
pd: Add "freeze" dual-role policy
Add a new DRP policy to "freeze" the power role of each port, never toggling automatically, though manual role swaps may still occur. BUG=chromium:769895 BRANCH=servo TEST=On servo_v4, verify DUT port stays in SRC role and POWER port stays in SNK role while disconnected. Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org> Change-Id: Ibff3cd1ffaf0e884b030c231003763a57acbe02e Reviewed-on: https://chromium-review.googlesource.com/715276 Commit-Ready: Shawn N <shawnn@chromium.org> Tested-by: Shawn N <shawnn@chromium.org> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'util')
-rw-r--r--util/ectool.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/util/ectool.c b/util/ectool.c
index ff41538b44..03aa6812d1 100644
--- a/util/ectool.c
+++ b/util/ectool.c
@@ -4414,7 +4414,8 @@ int cmd_usb_mux(int argc, char *argv[])
int cmd_usb_pd(int argc, char *argv[])
{
- const char *role_str[] = {"", "toggle", "toggle-off", "sink", "source"};
+ const char *role_str[] = {"", "toggle", "toggle-off", "sink", "source",
+ "freeze"};
const char *mux_str[] = {"", "none", "usb", "dp", "dock", "auto"};
const char *swap_str[] = {"", "dr_swap", "pr_swap", "vconn_swap"};
struct ec_params_usb_pd_control p;