diff options
author | Ting Shen <phoenixshen@google.com> | 2020-05-06 17:35:41 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-10-12 15:11:06 +0000 |
commit | b1c158ffa180b09d829e9c5a3372a9c71d23d67c (patch) | |
tree | 776e38c46d2722e9ce836103e7b4d98fd45dc50f | |
parent | cf09b73c1801519240c5e25ae8038edc912d1c1f (diff) | |
download | chrome-ec-b1c158ffa180b09d829e9c5a3372a9c71d23d67c.tar.gz |
rt946x: remove usb_charger_set_switches from board.h
Since all rt946x users do not customize usb_charger_set_switches(),
move this function into rt946x.c for the upcoming bc12 driver refactor.
A board can customize this function using the new bc12_drv if needed.
BUG=b:155611686
TEST=make buildall
BRANCH=none
Conflicts:
board/katsu/board.c: katsu board in branch only
Signed-off-by: Ting Shen <phoenixshen@google.com>
Change-Id: I8724af15c3508b54dc131a7c99004f3f4b2f893f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2187079
Tested-by: Ting Shen <phoenixshen@chromium.org>
Auto-Submit: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Eric Yilun Lin <yllin@chromium.org>
Commit-Queue: Eric Yilun Lin <yllin@chromium.org>
(cherry picked from commit 5e0b69a31b5964644693952f52a6339f66c5e260)
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3214014
Commit-Queue: Rong Chang <rongchang@chromium.org>
Tested-by: Rong Chang <rongchang@chromium.org>
Auto-Submit: Rong Chang <rongchang@chromium.org>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Eric Yilun Lin <yllin@google.com>
-rw-r--r-- | board/flapjack/board.c | 4 | ||||
-rw-r--r-- | board/kakadu/board.c | 4 | ||||
-rw-r--r-- | board/katsu/board.c | 4 | ||||
-rw-r--r-- | board/kodama/board.c | 4 | ||||
-rw-r--r-- | board/kukui/board.c | 4 | ||||
-rw-r--r-- | board/scarlet/board.c | 10 | ||||
-rw-r--r-- | driver/charger/rt946x.c | 4 |
7 files changed, 4 insertions, 30 deletions
diff --git a/board/flapjack/board.c b/board/flapjack/board.c index 0825361105..5f9c79ba89 100644 --- a/board/flapjack/board.c +++ b/board/flapjack/board.c @@ -614,10 +614,6 @@ int board_allow_i2c_passthru(int port) return (port == I2C_PORT_VIRTUAL_BATTERY); } -void usb_charger_set_switches(int port, enum usb_switch setting) -{ -} - int board_get_fod(uint8_t **fod) { *fod = NULL; diff --git a/board/kakadu/board.c b/board/kakadu/board.c index 712c4d12e2..75eb9ac112 100644 --- a/board/kakadu/board.c +++ b/board/kakadu/board.c @@ -460,10 +460,6 @@ void motion_interrupt(enum gpio_signal signal) #endif /* VARIANT_KUKUI_NO_SENSORS */ -void usb_charger_set_switches(int port, enum usb_switch setting) -{ -} - /* * Return if VBUS is sagging too low */ diff --git a/board/katsu/board.c b/board/katsu/board.c index 7cdae8b76a..4a39e17148 100644 --- a/board/katsu/board.c +++ b/board/katsu/board.c @@ -362,10 +362,6 @@ struct motion_sensor_t motion_sensors[] = { const unsigned int motion_sensor_count = ARRAY_SIZE(motion_sensors); #endif /* VARIANT_KUKUI_NO_SENSORS */ -void usb_charger_set_switches(int port, enum usb_switch setting) -{ -} - /* * Return if VBUS is sagging too low */ diff --git a/board/kodama/board.c b/board/kodama/board.c index c7aea72e72..5fb2ec15a7 100644 --- a/board/kodama/board.c +++ b/board/kodama/board.c @@ -369,10 +369,6 @@ struct motion_sensor_t motion_sensors[] = { const unsigned int motion_sensor_count = ARRAY_SIZE(motion_sensors); #endif /* SECTION_IS_RW */ -void usb_charger_set_switches(int port, enum usb_switch setting) -{ -} - /* * Return if VBUS is sagging too low */ diff --git a/board/kukui/board.c b/board/kukui/board.c index a753ae650d..bf65badb0f 100644 --- a/board/kukui/board.c +++ b/board/kukui/board.c @@ -546,10 +546,6 @@ const struct motion_sensor_t *motion_als_sensors[] = { }; #endif /* VARIANT_KUKUI_NO_SENSORS */ -void usb_charger_set_switches(int port, enum usb_switch setting) -{ -} - /* * Return if VBUS is sagging too low */ diff --git a/board/scarlet/board.c b/board/scarlet/board.c index b68864f908..95a5a2aff7 100644 --- a/board/scarlet/board.c +++ b/board/scarlet/board.c @@ -449,13 +449,3 @@ int board_allow_i2c_passthru(int port) { return (port == I2C_PORT_VIRTUAL_BATTERY); } - -void usb_charger_set_switches(int port, enum usb_switch setting) -{ - /* - * There is no USB2 switch anywhere on this board. But based - * on the discussion in b:65446459, RK3399's USB PHY is powered - * off when USB charging port detection is going on, so things - * should mostly work without a USB2 switch. - */ -} diff --git a/driver/charger/rt946x.c b/driver/charger/rt946x.c index 919cfd510d..706bd266f9 100644 --- a/driver/charger/rt946x.c +++ b/driver/charger/rt946x.c @@ -1556,6 +1556,10 @@ wait_event: } } +void usb_charger_set_switches(int port, enum usb_switch setting) +{ +} + int usb_charger_ramp_allowed(int supplier) { return supplier == CHARGE_SUPPLIER_BC12_DCP; |