summaryrefslogtreecommitdiff
path: root/board/kodama/board.c
diff options
context:
space:
mode:
authorDaisuke Nojiri <dnojiri@chromium.org>2019-08-13 12:36:08 -0700
committerCommit Bot <commit-bot@chromium.org>2019-08-14 18:55:16 +0000
commit29b86be6ba06f1de6973a6d2f4fa3c9eba8be0f1 (patch)
tree8ceeb0ad98e98e2335dfb37e5affabd808bfe3e1 /board/kodama/board.c
parenta18332870ba0f77eb686366d616201da6ff90527 (diff)
downloadchrome-ec-29b86be6ba06f1de6973a6d2f4fa3c9eba8be0f1.tar.gz
charge_manager: Mark functions overridable
Functions such as board_fill_source_power_info are overridable. This patch annotates them properly using override macros, and removes their declarations from board.h. These functions are declared in both charge_manager.h and {kukui,krane,kodama}/board.h. The latter causes comm-dev.c to fail to be compiled in chrome-base/diagnostics. BUG=none BRANCH=none TEST=buildall Change-Id: I27d6dfe2fa9299550ac5205c34095a4fe02dabdb Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1752597 Tested-by: Yu-Ping Wu <yupingso@chromium.org>
Diffstat (limited to 'board/kodama/board.c')
-rw-r--r--board/kodama/board.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/board/kodama/board.c b/board/kodama/board.c
index c16a841dca..a4a45bdb77 100644
--- a/board/kodama/board.c
+++ b/board/kodama/board.c
@@ -334,17 +334,18 @@ int board_is_vbus_too_low(int port, enum chg_ramp_vbus_state ramp_state)
return charger_get_vbus_voltage(port) < 4400;
}
-int board_charge_port_is_sink(int port)
+__override int board_charge_port_is_sink(int port)
{
/* TODO(b:128386458): Check POGO_ADC_INT_L */
return 1;
}
-int board_charge_port_is_connected(int port)
+__override int board_charge_port_is_connected(int port)
{
return gpio_get_level(GPIO_POGO_VBUS_PRESENT);
}
+__override
void board_fill_source_power_info(int port,
struct ec_response_usb_pd_power_info *r)
{