summaryrefslogtreecommitdiff
path: root/test/usb_typec_drp_acc_trysrc.c
diff options
context:
space:
mode:
authorAbe Levkoy <alevkoy@chromium.org>2020-12-07 17:39:09 -0700
committerCommit Bot <commit-bot@chromium.org>2020-12-15 15:39:18 +0000
commit0a561def48d4e673c834f4d01506ba8b9886cdd4 (patch)
treecbca0104ac3fe7058c0d58d14abd95decb39da6e /test/usb_typec_drp_acc_trysrc.c
parent160208413d16840428e42ecae18457e862e6ed49 (diff)
downloadchrome-ec-0a561def48d4e673c834f4d01506ba8b9886cdd4.tar.gz
mock: Clean up TCPMv2 mocks
Place mock functions in the mock libraries corresponding to the layers of the real implementations. Broadly, move towards one layer of the TCPM stack as a UUT, with mocks for the other layers as needed. There should be a one-to-one correspondence between real modules and mock modules. usb_pd_mock.c does not correspond to any real implementation module or TCPM stack layer, so remove it and move its contents to the layers corresponding to their real implementations. Also clean up some redundant or misplaced mocks inside tests. BUG=b:153071799,b:173791979 TEST=make buildall BRANCH=none Signed-off-by: Abe Levkoy <alevkoy@chromium.org> Change-Id: Ic44df8675de2b9f1f8c7669cd97dcdc296bf107f Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2578200 Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org> Commit-Queue: Paul Fagerburg <pfagerburg@chromium.org>
Diffstat (limited to 'test/usb_typec_drp_acc_trysrc.c')
-rw-r--r--test/usb_typec_drp_acc_trysrc.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/test/usb_typec_drp_acc_trysrc.c b/test/usb_typec_drp_acc_trysrc.c
index 605d133934..f33c7079cf 100644
--- a/test/usb_typec_drp_acc_trysrc.c
+++ b/test/usb_typec_drp_acc_trysrc.c
@@ -27,19 +27,6 @@
/* Unreachable time in future */
#define TIMER_DISABLED 0xffffffffffffffff
-/* TODO(b/153071799): Move these pd_* and pe_* function into mock */
-__overridable void pd_request_power_swap(int port)
-{}
-
-void pd_set_src_caps(int port, int cnt, uint32_t *src_caps)
-{
-}
-
-__overridable void pe_invalidate_explicit_contract(int port)
-{
-}
-/* End pd_ mock section */
-
/* Install Mock TCPC and MUX drivers */
const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_MAX_COUNT] = {
{