summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJett Rink <jettrink@chromium.org>2019-10-07 11:25:40 -0600
committerCommit Bot <commit-bot@chromium.org>2019-10-08 17:14:51 +0000
commit9c751ff7053b556af82a38164060256fc1ccef55 (patch)
tree3b4c694012bd70e54d7354460ec5b46dc6e39564
parent971d918309a6c041f67d14231560b2109da40adb (diff)
downloadchrome-ec-9c751ff7053b556af82a38164060256fc1ccef55.tar.gz
cleanup: moving define closer to use
BRANCH=none BUG=none TEST=builds Change-Id: Ifa60ca375fda22e6d5f79610f10ca1d5b4f2e894 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1845813 Reviewed-by: Edward Hill <ecgh@chromium.org>
-rw-r--r--common/usbc/usb_tc_vpd_sm.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/common/usbc/usb_tc_vpd_sm.c b/common/usbc/usb_tc_vpd_sm.c
index c03dfee772..479701d6b8 100644
--- a/common/usbc/usb_tc_vpd_sm.c
+++ b/common/usbc/usb_tc_vpd_sm.c
@@ -26,9 +26,6 @@
/* Type-C Layer Flags */
#define TC_FLAGS_VCONN_ON BIT(0)
-/* Constant used to force an initial debounce cycle */
-#define PD_CC_UNSET -1
-
/**
* This is the Type-C Port object that contains information needed to
* implement a VCONN Powered Device.
@@ -234,7 +231,9 @@ static void tc_unattached_snk_run(const int port)
static void tc_attach_wait_snk_entry(const int port)
{
print_current_state(port);
- tc[port].host_cc_state = PD_CC_UNSET;
+
+ /* Forces an initial debounce in run function */
+ tc[port].host_cc_state = -1;
}
static void tc_attach_wait_snk_run(const int port)