diff options
author | Diana Z <dzigterman@chromium.org> | 2020-12-16 23:29:04 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-12-24 01:11:02 +0000 |
commit | fca75f573ff913a5be050c7a13e7dcda6be68da2 (patch) | |
tree | dc192d0343545550a4f88df2d91f813d58d27d1a /board/asurada | |
parent | c9cc5600573a6a28bd0a66d43916e969bd403bbd (diff) | |
download | chrome-ec-fca75f573ff913a5be050c7a13e7dcda6be68da2.tar.gz |
TCPMv2: Update source-out configs
Now that the DPM will be handling source-out decisions for TCPMv2,
remove references to its old configuration options from TCPMv2 boards in
order to avoid any confusion as to what code is running now. Also
remove the charge manager notifications of sink attach/detach since the
policy is being centralized into the DPM.
Note that the previous configuration options only ever allocated one 3.0
A port, and so the default number of 3.0 A ports has been set to 1.
BRANCH=None
BUG=b:168862110,b:141690755
TEST=make -j buildall
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: Ie452e3da32b04226503539daa67b6b9f4a58aa58
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2597431
Reviewed-by: Keith Short <keithshort@chromium.org>
Diffstat (limited to 'board/asurada')
-rw-r--r-- | board/asurada/board.h | 1 | ||||
-rw-r--r-- | board/asurada/usb_pd_policy.c | 14 |
2 files changed, 2 insertions, 13 deletions
diff --git a/board/asurada/board.h b/board/asurada/board.h index 4c8ece2544..116cfc710e 100644 --- a/board/asurada/board.h +++ b/board/asurada/board.h @@ -125,7 +125,6 @@ #define CONFIG_USB_PD_FRS_TCPC #define CONFIG_USB_PD_ITE_ACTIVE_PORT_COUNT 2 #define CONFIG_USB_PD_LOGGING -#define CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT TYPEC_RP_3A0 #define CONFIG_USB_PD_PORT_MAX_COUNT 2 #define CONFIG_USB_PD_TCPC_LOW_POWER #define CONFIG_USB_PD_TCPMV2 diff --git a/board/asurada/usb_pd_policy.c b/board/asurada/usb_pd_policy.c index 7039f4e5f9..9e90eb95a3 100644 --- a/board/asurada/usb_pd_policy.c +++ b/board/asurada/usb_pd_policy.c @@ -10,8 +10,8 @@ #include "usb_pd.h" #include "usbc_ppc.h" -#ifndef CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT -#error Asurada reference must define CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT +#if CONFIG_USB_PD_3A_PORTS != 1 +#error Asurada reference must have at least one 3.0 A port #endif #define CPRINTS(format, args...) cprints(CC_USBPD, format, ## args) @@ -182,11 +182,6 @@ void pd_power_supply_reset(int port) if (prev_en) pd_set_vbus_discharge(port, 1); -#ifdef CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT - /* Give back the current quota we are no longer using */ - charge_manager_source_port(port, 0); -#endif /* defined(CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT) */ - /* Notify host of power info change. */ pd_send_host_event(PD_EVENT_POWER_CHANGE); } @@ -213,11 +208,6 @@ int pd_set_power_supply_ready(int port) if (rv) return rv; -#ifdef CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT - /* Ensure we advertise the proper available current quota */ - charge_manager_source_port(port, 1); -#endif /* defined(CONFIG_USB_PD_MAX_SINGLE_SOURCE_CURRENT) */ - /* Notify host of power info change. */ pd_send_host_event(PD_EVENT_POWER_CHANGE); |