summaryrefslogtreecommitdiff
path: root/include/usb_pd.h
diff options
context:
space:
mode:
authorShawn Nematbakhsh <shawnn@chromium.org>2015-06-23 17:52:00 -0700
committerChromeOS Commit Bot <chromeos-commit-bot@chromium.org>2015-06-30 17:18:37 +0000
commit1ef8c7dc2096405e815797fd06dec628a39b4e33 (patch)
tree8c45cc6b372317d6b66dbdc11bc883802e208521 /include/usb_pd.h
parent4114b7f1fe2274c0d1321cba8182ade8180599d9 (diff)
downloadchrome-ec-1ef8c7dc2096405e815797fd06dec628a39b4e33.tar.gz
usb_mux: Add driver interface for USB-C muxes
In preparation for adding support for additional USB-C mux chips, add a new high-level USB-C mux interface usb_mux.c. usb_mux functions are now called from pd code instead of board-level functions. usb_mux calls down into a mux chip-specific driver (currently pi3usb30532) or board-specific drivers which toggle GPIOs (for legacy boards). BUG=chrome-os-partner:41696 TEST=Manual on Glados in subsequent commit. Verify set() and get() functions set and return consistent values. Verify that USB SS device functions when muxes are set to dock or USB. Also, verify that DP dongle and USB SS device are functional on both PD ports on samus_pd. BRANCH=None Change-Id: Ib6477f489310f3be1430585ea09fea26f57e3752 Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/281435 Reviewed-by: Alec Berg <alecaberg@chromium.org>
Diffstat (limited to 'include/usb_pd.h')
-rw-r--r--include/usb_pd.h41
1 files changed, 0 insertions, 41 deletions
diff --git a/include/usb_pd.h b/include/usb_pd.h
index 8b915a14c4..e9edebb526 100644
--- a/include/usb_pd.h
+++ b/include/usb_pd.h
@@ -1186,14 +1186,6 @@ extern const int pd_snk_pdo_cnt;
*/
int pd_get_source_pdo(const uint32_t **src_pdo);
-/* Muxing for the USB type C */
-enum typec_mux {
- TYPEC_MUX_NONE,
- TYPEC_MUX_USB,
- TYPEC_MUX_DP,
- TYPEC_MUX_DOCK,
-};
-
enum usb_switch {
USB_SWITCH_CONNECT,
USB_SWITCH_DISCONNECT,
@@ -1209,39 +1201,6 @@ enum usb_switch {
void board_set_usb_switches(int port, enum usb_switch setting);
/**
- * Configure superspeed muxes on type-C port.
- *
- * @param port port number.
- * @param mux selected function.
- * @param polarity plug polarity (0=CC1, 1=CC2).
- */
-void board_set_usb_mux(int port, enum typec_mux mux,
- enum usb_switch usb, int polarity);
-
-/**
- * Query superspeed mux status on type-C port.
- *
- * @param port port number.
- * @param dp_str pointer to the DP string to return.
- * @param usb_str pointer to the USB string to return.
- * @return Non-zero if superspeed connection is enabled; otherwise, zero.
- */
-int board_get_usb_mux(int port, const char **dp_str, const char **usb_str);
-
-/**
- * Flip the superspeed muxes on type-C port.
- *
- * This is used for factory test automation. Note that this function should
- * only flip the superspeed muxes and leave CC lines alone. Without further
- * changes, this function MUST ONLY be used for testing purpose, because
- * the protocol layer loses track of the superspeed polarity and DP/USB3.0
- * connection may break.
- *
- * @param port port number.
- */
-void board_flip_usb_mux(int port);
-
-/**
* Request that a host event be sent to notify the AP of a PD power event.
*
* @param mask host event mask.