summaryrefslogtreecommitdiff
path: root/driver/usb_mux/anx7451.h
diff options
context:
space:
mode:
authorRob Barnes <robbarnes@google.com>2021-04-20 12:35:07 -0600
committerCommit Bot <commit-bot@chromium.org>2021-04-22 22:40:37 +0000
commit94af8e1d5e4203f0e5af0732b8adff0649241ddc (patch)
treecceb510f9080c9ecad9c0c7edd2ebc91b13cee5d /driver/usb_mux/anx7451.h
parent964d97811ecf157c5436288d0aad9ba399e4dd72 (diff)
downloadchrome-ec-94af8e1d5e4203f0e5af0732b8adff0649241ddc.tar.gz
ANX7451: Add power off and wake up routines
Add anx7451_power_off and anx7451_wake_up routines. ANX7451 is powered off whenever both USB and DP are disabled. ANX7451 is woken up via i2c before mux set or get. BUG=b:184907521 TEST=Mux is powering off when nothing is connected. Mux is waking up when cable is connected. BRANCH=None Signed-off-by: Rob Barnes <robbarnes@google.com> Change-Id: Idf1343735cb94eb8bbaebe93794195d2f115b086 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2840056 Reviewed-by: Diana Z <dzigterman@chromium.org>
Diffstat (limited to 'driver/usb_mux/anx7451.h')
-rw-r--r--driver/usb_mux/anx7451.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/driver/usb_mux/anx7451.h b/driver/usb_mux/anx7451.h
index c8d302f5c9..cf7a701f6c 100644
--- a/driver/usb_mux/anx7451.h
+++ b/driver/usb_mux/anx7451.h
@@ -15,6 +15,10 @@
#define ANX7451_I2C_ADDR2_FLAGS 0x16
#define ANX7451_I2C_ADDR3_FLAGS 0x11
+/* This register is not documented in datasheet. */
+#define ANX7451_REG_POWER_CNTRL 0x2B
+#define ANX7451_POWER_CNTRL_OFF 0xFF
+
/*
* Ultra low power control register.
* On ANX7451, this register should always be 0 (disabled).