diff options
author | Jett Rink <jettrink@chromium.org> | 2018-08-31 09:11:14 -0600 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2018-09-17 21:35:01 -0700 |
commit | a914c8df696d4fd8cc8d7bbdfe99da539606fcf9 (patch) | |
tree | 8c0548d615e8bb84de4b04effb0f945ab7fda891 /board | |
parent | 3552760ea58d796a7fb27b3c32d7a0ce8243f6fa (diff) | |
download | chrome-ec-a914c8df696d4fd8cc8d7bbdfe99da539606fcf9.tar.gz |
ss-mux: remove unused port_addr initializationv2.0.0
We do not need to set the port_addr variable most places because the
SS-MUX is also the TCPC and the tcpc_config_t information is used
instead.
Remove unused variable setting to avoid confusion.
BRANCH=none
BUG=none
TEST=buildall. phaser USB-C communication (and muxs) still work which is
a nominal case for all of these changes.
Change-Id: I72ee5da251956eb133091974e8dce5ac7f8787c6
Signed-off-by: Jett Rink <jettrink@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1200064
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Edward Hill <ecgh@chromium.org>
Diffstat (limited to 'board')
-rw-r--r-- | board/atlas/board.c | 2 | ||||
-rw-r--r-- | board/cheza/board.c | 2 | ||||
-rw-r--r-- | board/coral/board.c | 2 | ||||
-rw-r--r-- | board/elm/board.c | 1 | ||||
-rw-r--r-- | board/eve/board.c | 2 | ||||
-rw-r--r-- | board/fizz/board.c | 1 | ||||
-rw-r--r-- | board/kukui/board.c | 1 | ||||
-rw-r--r-- | board/nami/board.c | 2 | ||||
-rw-r--r-- | board/nautilus/board.c | 2 | ||||
-rw-r--r-- | board/nocturne/board.c | 3 | ||||
-rw-r--r-- | board/pdeval-stm32f072/usb_pd_policy.c | 1 | ||||
-rw-r--r-- | board/poppy/board.c | 2 | ||||
-rw-r--r-- | board/rainier/board.c | 1 | ||||
-rw-r--r-- | board/rammus/board.c | 2 | ||||
-rw-r--r-- | board/reef/board.c | 2 | ||||
-rw-r--r-- | board/reef_mchp/board.c | 2 | ||||
-rw-r--r-- | board/rowan/board.c | 1 | ||||
-rw-r--r-- | board/samus_pd/usb_mux.c | 6 | ||||
-rw-r--r-- | board/scarlet/board.c | 1 | ||||
-rw-r--r-- | board/zoombini/board.c | 5 |
20 files changed, 3 insertions, 38 deletions
diff --git a/board/atlas/board.c b/board/atlas/board.c index 6e403bfd8f..aec1967d13 100644 --- a/board/atlas/board.c +++ b/board/atlas/board.c @@ -184,12 +184,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, { - .port_addr = 1, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, diff --git a/board/cheza/board.c b/board/cheza/board.c index 3e176736fd..b2b323eefd 100644 --- a/board/cheza/board.c +++ b/board/cheza/board.c @@ -225,12 +225,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = USB_PD_PORT_ANX3429, .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, { - .port_addr = USB_PD_PORT_PS8751, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, } diff --git a/board/coral/board.c b/board/coral/board.c index e651561e11..2c56f36b0b 100644 --- a/board/coral/board.c +++ b/board/coral/board.c @@ -287,12 +287,10 @@ static int ps8751_tune_mux(int port) struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { [USB_PD_PORT_ANX74XX] = { - .port_addr = USB_PD_PORT_ANX74XX, .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, [USB_PD_PORT_PS8751] = { - .port_addr = USB_PD_PORT_PS8751, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, .board_init = &ps8751_tune_mux, diff --git a/board/elm/board.c b/board/elm/board.c index 67a60d1aed..4fe7f780a0 100644 --- a/board/elm/board.c +++ b/board/elm/board.c @@ -157,7 +157,6 @@ BUILD_ASSERT(ARRAY_SIZE(temp_sensors) == TEMP_SENSOR_COUNT); struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, /* port idx */ .driver = &anx7688_usb_mux_driver, }, }; diff --git a/board/eve/board.c b/board/eve/board.c index e4ff6ad44a..df95551535 100644 --- a/board/eve/board.c +++ b/board/eve/board.c @@ -226,12 +226,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, { - .port_addr = 1, .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, diff --git a/board/fizz/board.c b/board/fizz/board.c index 2c2877c0c1..ac51d43c22 100644 --- a/board/fizz/board.c +++ b/board/fizz/board.c @@ -210,7 +210,6 @@ static int ps8751_tune_mux(int port) struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, .board_init = &ps8751_tune_mux, diff --git a/board/kukui/board.c b/board/kukui/board.c index 5d610c83a4..d86beb1e46 100644 --- a/board/kukui/board.c +++ b/board/kukui/board.c @@ -147,7 +147,6 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &virtual_usb_mux_driver, .hpd_update = &virtual_hpd_update, }, diff --git a/board/nami/board.c b/board/nami/board.c index cb5efe7bf6..75bfa139ec 100644 --- a/board/nami/board.c +++ b/board/nami/board.c @@ -228,12 +228,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = USB_PD_PORT_PS8751, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, { - .port_addr = USB_PD_PORT_ANX7447, .driver = &anx7447_usb_mux_driver, .hpd_update = &anx7447_tcpc_update_hpd_status, } diff --git a/board/nautilus/board.c b/board/nautilus/board.c index e765064bf6..c98de155d7 100644 --- a/board/nautilus/board.c +++ b/board/nautilus/board.c @@ -183,12 +183,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, { - .port_addr = 1, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, } diff --git a/board/nocturne/board.c b/board/nocturne/board.c index fd61390cc1..5d3f494127 100644 --- a/board/nocturne/board.c +++ b/board/nocturne/board.c @@ -300,16 +300,13 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { }, }; -/* The port_addr members are PD port numbers, not I2C port numbers. */ struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, { - .port_addr = 1, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, diff --git a/board/pdeval-stm32f072/usb_pd_policy.c b/board/pdeval-stm32f072/usb_pd_policy.c index 0b858e58e3..ba899f5efb 100644 --- a/board/pdeval-stm32f072/usb_pd_policy.c +++ b/board/pdeval-stm32f072/usb_pd_policy.c @@ -38,7 +38,6 @@ const int pd_snk_pdo_cnt = ARRAY_SIZE(pd_snk_pdo); #if defined(CONFIG_USB_PD_TCPM_MUX) && defined(CONFIG_USB_PD_TCPM_ANX7447) struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &anx7447_usb_mux_driver, }, }; diff --git a/board/poppy/board.c b/board/poppy/board.c index 20c57d6388..3a158ef050 100644 --- a/board/poppy/board.c +++ b/board/poppy/board.c @@ -225,12 +225,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, /* don't care / unused */ .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, { - .port_addr = 1, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, } diff --git a/board/rainier/board.c b/board/rainier/board.c index c3b7fab020..9e98136127 100644 --- a/board/rainier/board.c +++ b/board/rainier/board.c @@ -135,7 +135,6 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &virtual_usb_mux_driver, .hpd_update = &virtual_hpd_update, }, diff --git a/board/rammus/board.c b/board/rammus/board.c index 3f3be06943..1ae366f68a 100644 --- a/board/rammus/board.c +++ b/board/rammus/board.c @@ -174,12 +174,10 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { [USB_PD_PORT_PS8751] = { - .port_addr = USB_PD_PORT_PS8751, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, [USB_PD_PORT_ANX7447] = { - .port_addr = USB_PD_PORT_ANX7447, .driver = &anx7447_usb_mux_driver, .hpd_update = &anx7447_tcpc_update_hpd_status, } diff --git a/board/reef/board.c b/board/reef/board.c index 54766f73b9..a0a9a0ee4c 100644 --- a/board/reef/board.c +++ b/board/reef/board.c @@ -292,12 +292,10 @@ static int ps8751_tune_mux(int port) struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { [USB_PD_PORT_ANX74XX] = { - .port_addr = USB_PD_PORT_ANX74XX, .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, [USB_PD_PORT_PS8751] = { - .port_addr = USB_PD_PORT_PS8751, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, .board_init = &ps8751_tune_mux, diff --git a/board/reef_mchp/board.c b/board/reef_mchp/board.c index 91dc329b0c..733c345359 100644 --- a/board/reef_mchp/board.c +++ b/board/reef_mchp/board.c @@ -432,12 +432,10 @@ static int ps8751_tune_mux(int port) */ struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { [USB_PD_PORT_ANX74XX] = { - .port_addr = USB_PD_PORT_ANX74XX, .driver = &anx74xx_tcpm_usb_mux_driver, .hpd_update = &anx74xx_tcpc_update_hpd_status, }, [USB_PD_PORT_PS8751] = { - .port_addr = USB_PD_PORT_PS8751, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, .board_init = &ps8751_tune_mux, diff --git a/board/rowan/board.c b/board/rowan/board.c index 15c54b8392..64d2f39239 100644 --- a/board/rowan/board.c +++ b/board/rowan/board.c @@ -158,7 +158,6 @@ BUILD_ASSERT(ARRAY_SIZE(temp_sensors) == TEMP_SENSOR_COUNT); struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, /* port idx */ .driver = &anx7688_usb_mux_driver, }, }; diff --git a/board/samus_pd/usb_mux.c b/board/samus_pd/usb_mux.c index e37dd08037..268c0c5843 100644 --- a/board/samus_pd/usb_mux.c +++ b/board/samus_pd/usb_mux.c @@ -107,11 +107,9 @@ const struct usb_mux_driver board_custom_usb_mux_driver = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, - .driver = &board_custom_usb_mux_driver, + .driver = &board_custom_usb_mux_driver, }, { - .port_addr = 1, - .driver = &board_custom_usb_mux_driver, + .driver = &board_custom_usb_mux_driver, }, }; diff --git a/board/scarlet/board.c b/board/scarlet/board.c index adfee70cd7..6a21406697 100644 --- a/board/scarlet/board.c +++ b/board/scarlet/board.c @@ -131,7 +131,6 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &virtual_usb_mux_driver, .hpd_update = &virtual_hpd_update, }, diff --git a/board/zoombini/board.c b/board/zoombini/board.c index 0fd3f28518..a17d1465f4 100644 --- a/board/zoombini/board.c +++ b/board/zoombini/board.c @@ -393,23 +393,20 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = { #endif /* defined(BOARD_ZOOMBINI) */ }; -/* The port_addr members are PD port numbers, not I2C port numbers. */ +/* The order is PD port (same as tcpc) */ struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { { - .port_addr = 0, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, { - .port_addr = 1, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, #ifdef BOARD_ZOOMBINI { - .port_addr = 2, .driver = &tcpci_tcpm_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, }, |