common/usbc/usb_pd_console.c: Format with clang-format
BRANCH=none
TEST=none
#ifndef TEST_USB_PD_CONSOLE
static
#endif
-int command_pd(int argc, char **argv)
+ int
+ command_pd(int argc, char **argv)
{
int port;
char *e;
@@ -161,19 +162,18 @@ int command_pd(int argc, char **argv)
if (!strcasecmp(argv[2], "state")) {
cflush();
- ccprintf("Port C%d CC%d, %s - Role: %s-%s",
- port, pd_get_polarity(port) + 1,
+ ccprintf("Port C%d CC%d, %s - Role: %s-%s", port,
+ pd_get_polarity(port) + 1,
pd_comm_is_enabled(port) ? "Enable" : "Disable",
- pd_get_power_role(port) ==
- PD_ROLE_SOURCE ? "SRC" : "SNK",
+ pd_get_power_role(port) == PD_ROLE_SOURCE ? "SRC" :
+ "SNK",
pd_get_data_role(port) == PD_ROLE_DFP ? "DFP" : "UFP");
if (IS_ENABLED(CONFIG_USBC_VCONN))
ccprintf("%s ", tc_is_vconn_src(port) ? "-VC" : "");
ccprintf("TC State: %s, Flags: 0x%04x",
- tc_get_current_state(port),
- tc_get_flags(port));
+ tc_get_current_state(port), tc_get_flags(port));
if (IS_ENABLED(CONFIG_USB_PE_SM))
ccprintf(" PE State: %s, Flags: 0x%04x\n",
@@ -189,8 +189,7 @@ int command_pd(int argc, char **argv)
ccprintf("Port C%d CC%d\n", port, pd_get_task_cc_state(port));
}
- if (IS_ENABLED(CONFIG_CMD_PD_TIMER) &&
- !strcasecmp(argv[2], "timer")) {
+ if (IS_ENABLED(CONFIG_CMD_PD_TIMER) && !strcasecmp(argv[2], "timer")) {
pd_timer_dump(port);
}
