summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack Rosenthal <jrosenth@chromium.org>2022-07-06 11:45:14 -0600
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-07-07 22:20:38 +0000
commit66c01d8932b262fd3ceec80a1320d793668baae9 (patch)
treefa84ed2478019ed600eb60fa237d22d6bdb64fe1
parent0c40e309a77b9041a8415da4c4a18a2ebe5f3003 (diff)
downloadchrome-ec-66c01d8932b262fd3ceec80a1320d793668baae9.tar.gz
include/usb_pd_timer.h: Format with clang-format
BUG=b:236386294 BRANCH=none TEST=none Tricium: disable Change-Id: I7d4ef8e73349c70bde48f0af285a2812d8f36dba Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3730445 Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
-rw-r--r--include/usb_pd_timer.h35
1 files changed, 16 insertions, 19 deletions
diff --git a/include/usb_pd_timer.h b/include/usb_pd_timer.h
index 3a3f388b22..b4f8946780 100644
--- a/include/usb_pd_timer.h
+++ b/include/usb_pd_timer.h
@@ -167,7 +167,6 @@ enum pd_task_timer {
*/
PE_TIMER_WAIT_AND_ADD_JITTER,
-
/* Chunk Sender Response timer */
PR_TIMER_CHUNK_SENDER_RESPONSE,
@@ -183,7 +182,6 @@ enum pd_task_timer {
/* timeout to limit waiting on TCPC response (not in spec) */
PR_TIMER_TCPC_TX_TIMEOUT,
-
/* Time a port shall wait before it can determine it is attached */
TC_TIMER_CC_DEBOUNCE,
@@ -226,14 +224,14 @@ enum pd_timer_range {
PR_TIMER_RANGE,
TC_TIMER_RANGE,
};
-#define PE_TIMER_START PE_TIMER_BIST_CONT_MODE
-#define PE_TIMER_END PE_TIMER_WAIT_AND_ADD_JITTER
+#define PE_TIMER_START PE_TIMER_BIST_CONT_MODE
+#define PE_TIMER_END PE_TIMER_WAIT_AND_ADD_JITTER
-#define PR_TIMER_START PR_TIMER_CHUNK_SENDER_RESPONSE
-#define PR_TIMER_END PR_TIMER_TCPC_TX_TIMEOUT
+#define PR_TIMER_START PR_TIMER_CHUNK_SENDER_RESPONSE
+#define PR_TIMER_END PR_TIMER_TCPC_TX_TIMEOUT
-#define TC_TIMER_START TC_TIMER_CC_DEBOUNCE
-#define TC_TIMER_END TC_TIMER_VBUS_DEBOUNCE
+#define TC_TIMER_START TC_TIMER_CC_DEBOUNCE
+#define TC_TIMER_END TC_TIMER_VBUS_DEBOUNCE
/*
* pd_timer_init
@@ -311,7 +309,6 @@ void pd_timer_manage_expired(int port);
*/
int pd_timer_next_expiration(int port);
-
/*
* pd_timer_dump
* Debug display of the timers for a given port
@@ -333,30 +330,30 @@ void pd_timer_dump(int port);
*/
/* exported: number of USB-C ports */
-#define MAX_PD_PORTS CONFIG_USB_PD_PORT_MAX_COUNT
+#define MAX_PD_PORTS CONFIG_USB_PD_PORT_MAX_COUNT
/* PD timers have three possible states: Active, Inactive and Disabled */
/* exported: timer_active indicates if a timer is currently active */
-extern ATOMIC_DEFINE(timer_active, PD_TIMER_COUNT * MAX_PD_PORTS);
+extern ATOMIC_DEFINE(timer_active, PD_TIMER_COUNT *MAX_PD_PORTS);
/* exported: timer_disabled indicates if a timer is currently disabled */
-extern ATOMIC_DEFINE(timer_disabled, PD_TIMER_COUNT * MAX_PD_PORTS);
+extern ATOMIC_DEFINE(timer_disabled, PD_TIMER_COUNT *MAX_PD_PORTS);
/* exported: set/clear/check the current timer_active for a timer */
#define PD_SET_ACTIVE(p, bit) \
- atomic_set_bit(timer_active, (p) * PD_TIMER_COUNT + (bit))
+ atomic_set_bit(timer_active, (p)*PD_TIMER_COUNT + (bit))
#define PD_CLR_ACTIVE(p, bit) \
- atomic_clear_bit(timer_active, (p) * PD_TIMER_COUNT + (bit))
+ atomic_clear_bit(timer_active, (p)*PD_TIMER_COUNT + (bit))
#define PD_CHK_ACTIVE(p, bit) \
- atomic_test_bit(timer_active, (p) * PD_TIMER_COUNT + (bit))
+ atomic_test_bit(timer_active, (p)*PD_TIMER_COUNT + (bit))
/* exported: set/clear/check the current timer_disabled for a timer */
#define PD_SET_DISABLED(p, bit) \
- atomic_set_bit(timer_disabled, (p) * PD_TIMER_COUNT + (bit))
+ atomic_set_bit(timer_disabled, (p)*PD_TIMER_COUNT + (bit))
#define PD_CLR_DISABLED(p, bit) \
- atomic_clear_bit(timer_disabled, (p) * PD_TIMER_COUNT + (bit))
+ atomic_clear_bit(timer_disabled, (p)*PD_TIMER_COUNT + (bit))
#define PD_CHK_DISABLED(p, bit) \
- atomic_test_bit(timer_disabled, (p) * PD_TIMER_COUNT + (bit))
+ atomic_test_bit(timer_disabled, (p)*PD_TIMER_COUNT + (bit))
#endif /* TEST_BUILD */
-#endif /* __CROS_EC_USB_PD_TIMER_H */
+#endif /* __CROS_EC_USB_PD_TIMER_H */