summaryrefslogtreecommitdiff
path: root/common/usb_pd_policy.c
diff options
context:
space:
mode:
authorDenis Brockus <dbrockus@chromium.org>2020-01-08 07:59:42 -0700
committerCommit Bot <commit-bot@chromium.org>2020-01-09 19:24:11 +0000
commit4ae38ae35d55559feb1524bdbc1482ca7c858f2b (patch)
treeeebeb418c36bf28914cc02452f74dd494842cea9 /common/usb_pd_policy.c
parentd3a1820df21b12842232ab88a5c1a0490640bb25 (diff)
downloadchrome-ec-4ae38ae35d55559feb1524bdbc1482ca7c858f2b.tar.gz
pd: cleanup pd_get_data_role
This is the second half of b/147290482 Cleaning up to use pd_data_role instead of int BUG=b:147314832 BRANCH=none TEST=make buildall -j Change-Id: I2445b06f5f5469fb1f3a968034a83e3ee792e7c7 Signed-off-by: Denis Brockus <dbrockus@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1991845 Reviewed-by: Jett Rink <jettrink@chromium.org> Reviewed-by: Edward Hill <ecgh@chromium.org>
Diffstat (limited to 'common/usb_pd_policy.c')
-rw-r--r--common/usb_pd_policy.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/common/usb_pd_policy.c b/common/usb_pd_policy.c
index 69066eb3cf..cdce3e5390 100644
--- a/common/usb_pd_policy.c
+++ b/common/usb_pd_policy.c
@@ -172,7 +172,9 @@ static bool is_transmit_msg_sop_prime(int port)
(cable[port].flags & CABLE_FLAGS_SOP_PRIME_ENABLE));
}
-uint8_t is_sop_prime_ready(int port, uint8_t data_role, uint32_t pd_flags)
+uint8_t is_sop_prime_ready(int port,
+ enum pd_data_role data_role,
+ uint32_t pd_flags)
{
/*
* Ref: USB PD 3.0 sec 2.5.4: When an Explicit Contract is in place the