diff options
author | Jack Rosenthal <jrosenth@chromium.org> | 2022-06-27 14:05:46 -0600 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-06-30 19:41:32 +0000 |
commit | 2a6dec3e383d0008354fcb86c921c2308effacfd (patch) | |
tree | bfcc26db20dc18fa928cfdac83921b6bcb5fd87e /board/shuboz | |
parent | 9d81a0b39501c8bf23b20595097df3b311b56b0b (diff) | |
download | chrome-ec-2a6dec3e383d0008354fcb86c921c2308effacfd.tar.gz |
board/shuboz/board.c: Format with clang-format
BUG=b:236386294
BRANCH=none
TEST=none
Change-Id: Ib115d67f9762ff4b8556ecef2bd68fadb3a69680
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3728942
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Diffstat (limited to 'board/shuboz')
-rw-r--r-- | board/shuboz/board.c | 33 |
1 files changed, 12 insertions, 21 deletions
diff --git a/board/shuboz/board.c b/board/shuboz/board.c index 027a6ee634..220ca09541 100644 --- a/board/shuboz/board.c +++ b/board/shuboz/board.c @@ -39,8 +39,8 @@ #include "usb_pd_tcpm.h" #include "usbc_ppc.h" -#define CPRINTSUSB(format, args...) cprints(CC_USBCHARGE, format, ## args) -#define CPRINTFUSB(format, args...) cprintf(CC_USBCHARGE, format, ## args) +#define CPRINTSUSB(format, args...) cprints(CC_USBCHARGE, format, ##args) +#define CPRINTFUSB(format, args...) cprintf(CC_USBCHARGE, format, ##args) /* This I2C moved. Temporarily detect and support the V0 HW. */ int I2C_PORT_BATTERY = I2C_PORT_BATTERY_V1; @@ -62,15 +62,13 @@ static const mat33_fp_t lid_standard_ref = { { 0, FLOAT_TO_FP(-1), 0 }, { 0, 0, FLOAT_TO_FP(-1) }, }; -static const mat33_fp_t base_standard_ref = { - { 0, FLOAT_TO_FP(-1), 0}, - { FLOAT_TO_FP(-1), 0, 0}, - { 0, 0, FLOAT_TO_FP(-1)} -}; +static const mat33_fp_t base_standard_ref = { { 0, FLOAT_TO_FP(-1), 0 }, + { FLOAT_TO_FP(-1), 0, 0 }, + { 0, 0, FLOAT_TO_FP(-1) } }; static const mat33_fp_t base_standard_ref_icm = { - {FLOAT_TO_FP(1), 0, 0}, - {0, FLOAT_TO_FP(-1), 0}, - {0, 0, FLOAT_TO_FP(-1)}, + { FLOAT_TO_FP(1), 0, 0 }, + { 0, FLOAT_TO_FP(-1), 0 }, + { 0, 0, FLOAT_TO_FP(-1) }, }; /* TODO(gcc >= 5.0) Remove the casts to const pointer at rot_standard_ref */ @@ -226,8 +224,7 @@ static void board_chipset_suspend(void) } DECLARE_HOOK(HOOK_CHIPSET_SUSPEND, board_chipset_suspend, HOOK_PRIO_DEFAULT); -static int board_ps8743_mux_set(const struct usb_mux *me, - mux_state_t mux_state) +static int board_ps8743_mux_set(const struct usb_mux *me, mux_state_t mux_state) { int res; @@ -242,7 +239,6 @@ static int board_ps8743_mux_set(const struct usb_mux *me, return res; } - /***************************************************************************** * USB-C */ @@ -350,8 +346,7 @@ void ppc_interrupt(enum gpio_signal signal) int board_set_active_charge_port(int port) { - int is_valid_port = (port >= 0 && - port < CONFIG_USB_PD_PORT_MAX_COUNT); + int is_valid_port = (port >= 0 && port < CONFIG_USB_PD_PORT_MAX_COUNT); int i; if (port == CHARGE_PORT_NONE) { @@ -372,7 +367,6 @@ int board_set_active_charge_port(int port) return EC_ERROR_INVAL; } - /* Check if the port is sourcing VBUS. */ if (ppc_is_sourcing_vbus(port)) { CPRINTFUSB("Skip enable C%d", port); @@ -474,7 +468,6 @@ static void reset_nct38xx_port(int port) msleep(NCT3807_RESET_POST_DELAY_MS); } - void board_reset_pd_mcu(void) { /* Reset TCPC0 */ @@ -545,11 +538,9 @@ int board_pd_set_frs_enable(int port, int enable) /* Use the TCPC to enable fast switch when FRS included */ if (port == USBC_PORT_C0) { - rv = ioex_set_level(IOEX_USB_C0_TCPC_FASTSW_CTL_EN, - !!enable); + rv = ioex_set_level(IOEX_USB_C0_TCPC_FASTSW_CTL_EN, !!enable); } else { - rv = ioex_set_level(IOEX_USB_C1_TCPC_FASTSW_CTL_EN, - !!enable); + rv = ioex_set_level(IOEX_USB_C1_TCPC_FASTSW_CTL_EN, !!enable); } return rv; |