diff options
author | Denis Brockus <dbrockus@chromium.org> | 2019-11-21 07:30:54 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-11-25 22:17:24 +0000 |
commit | f9fd94f64d3294c2005048164361e3697d63a7bb (patch) | |
tree | d408036789da808cc6be0d2b4b08ad9e8f6c6970 /include/usb_mux.h | |
parent | a621ea9f352a7fdd5fa41982bfc4c13f1e351f3c (diff) | |
download | chrome-ec-f9fd94f64d3294c2005048164361e3697d63a7bb.tar.gz |
usbc: make BB virtual mux retimer compatible with non-virtual
Changed the driver interface for BB virtual mux retimer to
stop using global functions and use the usb_retimers array
instead.
BUG=none
BRANCH=none
TEST=make buildall -j
Change-Id: I56befaca1720eb2f4e0599a983629b4df45dc76b
Signed-off-by: Denis Brockus <dbrockus@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1928121
Reviewed-by: Edward Hill <ecgh@chromium.org>
Commit-Queue: Edward Hill <ecgh@chromium.org>
Diffstat (limited to 'include/usb_mux.h')
-rw-r--r-- | include/usb_mux.h | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/include/usb_mux.h b/include/usb_mux.h index 0a5a19a338..c0e781f65d 100644 --- a/include/usb_mux.h +++ b/include/usb_mux.h @@ -178,20 +178,23 @@ struct usb_retimer_driver { struct usb_retimer { /* * All of the fields are provided on an as needed basis. - * If your retimer does not perform I2C operations, then - * values would not be set. This includes the driver - * field, which would indicate no retimer driver is to - * be called. Values that are not specifically popuplated - * shall be 0/NULL. + * If your retimer does not use the provided machanism then + * values would not be set (defaulted to 0/NULL). This + * defaulting includes the driver field, which would indicate + * no retimer driver is to be called. */ /* I2C port and slave address */ const int i2c_port; const uint16_t i2c_addr_flags; - /* GPIOs for enabling the retimer and DP mode */ - const int gpio_enable; - const int gpio_dp_enable; + /* Retimer control GPIOs */ + const enum gpio_signal gpio_enable; /* Retimer enable */ + const enum gpio_signal gpio_dp_enable; /* DP Mode enable */ + + const enum gpio_signal usb_ls_en_gpio; /* Load switch enable */ + const enum gpio_signal retimer_rst_gpio;/* Retimer reset */ + const enum gpio_signal force_power_gpio;/* Force power (active/low) */ /* Driver interfaces for this retimer */ const struct usb_retimer_driver *driver; |