summaryrefslogtreecommitdiff
path: root/board/reef_mchp
diff options
context:
space:
mode:
authorDiana Z <dzigterman@chromium.org>2021-02-16 11:21:46 -0700
committerCommit Bot <commit-bot@chromium.org>2021-02-24 19:09:52 +0000
commit3fcd85217ef404a9dc343887766949ebb9febcba (patch)
tree2fb2a7571af2400b66c33ccce4b1d1af99141618 /board/reef_mchp
parent4cd6d9cede73423e21ca01405e5eae820487748f (diff)
downloadchrome-ec-3fcd85217ef404a9dc343887766949ebb9febcba.tar.gz
COIL: Remove unused mchp i2c function
Remove i2c function and data structures which are currently unused in the codebase. The calling location of this function was removed in 2018. This commit also updates comments in the board header files which were using the function. BRANCH=None BUG=None TEST=make -j buildall Signed-off-by: Diana Z <dzigterman@chromium.org> Change-Id: I46cd0d95e750489b633a99dde56e267562f577e1 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2697858 Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Diffstat (limited to 'board/reef_mchp')
-rw-r--r--board/reef_mchp/board.c32
-rw-r--r--board/reef_mchp/board.h8
2 files changed, 1 insertions, 39 deletions
diff --git a/board/reef_mchp/board.c b/board/reef_mchp/board.c
index c63cee981a..feb363156e 100644
--- a/board/reef_mchp/board.c
+++ b/board/reef_mchp/board.c
@@ -232,16 +232,6 @@ const uint16_t i2c_port_to_ctrl[I2C_PORT_COUNT] = {
(MCHP_I2C_CTRL3 << 8) + MCHP_I2C_PORT7,
};
-/*
- * Used by chip level I2C controller initialization.
- * Board level can specify two unused I2C addresses
- * for each controller. Current chip level disables
- * controller response to address 0(general call).
- */
-const uint32_t i2c_ctrl_slave_addrs[I2C_CONTROLLER_COUNT] = {
- 0, 0, 0, 0,
-};
-
const struct charger_config_t chg_chips[] = {
{
.i2c_port = I2C_PORT_CHARGER,
@@ -250,26 +240,6 @@ const struct charger_config_t chg_chips[] = {
},
};
-/* Return the two slave addresses the specified
- * controller will respond to when controller
- * is acting as a slave.
- * b[6:0] = b[7:1] of I2C address 1
- * b[14:8] = b[7:1] of I2C address 2
- * When not using I2C controllers as slaves we can use
- * the same value for all controllers. The address should
- * not be 0x00 as this is the general call address.
- */
-uint16_t board_i2c_slave_addrs(int controller)
-{
- int i;
-
- for (i = 0; i < I2C_CONTROLLER_COUNT; i++)
- if ((i2c_ctrl_slave_addrs[i] & 0xffff) == controller)
- return (i2c_ctrl_slave_addrs[i] >> 16);
-
- return 0; /* general call address */
-}
-
/*
* default to I2C0 because callers may not check
* return value if we returned an error code.
@@ -420,7 +390,7 @@ static int ps8751_tune_mux(const struct usb_mux *me)
/*
* USB_PD_PORT_ANX74XX and USB_PD_PORT_PS8751 are zero based indices into
* tcpc_config array. The tcpc_config array contains the actual EC I2C
- * port, device slave address, and a function pointer into the driver code.
+ * port, device address, and a function pointer into the driver code.
*/
const struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_MAX_COUNT] = {
[USB_PD_PORT_ANX74XX] = {
diff --git a/board/reef_mchp/board.h b/board/reef_mchp/board.h
index 01ec4aa79c..fedfc82edd 100644
--- a/board/reef_mchp/board.h
+++ b/board/reef_mchp/board.h
@@ -316,14 +316,6 @@ void board_print_tcpc_fw_version(int port);
/* Map I2C port to controller */
int board_i2c_p2c(int port);
-/* Return the two slave addresses the specified
- * controller will respond to when controller
- * is acting as a slave.
- * b[6:0] = b[7:1] of I2C address 1
- * b[14:8] = b[7:1] of I2C address 2
- */
-uint16_t board_i2c_slave_addrs(int controller);
-
/* MCHP - firwmare-reef-9042.B does have LID_ALS bit
* because its using TASK_ALS ?
*/