board/plankton/usb_pd_config.h: Format with clang-format
BRANCH=none
TEST=none
@@ -92,9 +92,8 @@ static inline void pd_tx_disable(int port, int polarity)
{
/* output low on SPI TX to disable the FET */
/* PA6 is SPI1_MISO */
- STM32_GPIO_MODER(GPIO_A) = (STM32_GPIO_MODER(GPIO_A)
- & ~(3 << (2*6)))
- | (1 << (2*6));
+ STM32_GPIO_MODER(GPIO_A) =
+ (STM32_GPIO_MODER(GPIO_A) & ~(3 << (2 * 6))) | (1 << (2 * 6));
/* put the low level reference in Hi-Z */
gpio_set_level(GPIO_USBC_CC1_TX_EN, 0);
gpio_set_level(GPIO_USBC_CC2_TX_EN, 0);
@@ -104,10 +103,9 @@ static inline void pd_tx_disable(int port, int polarity)
static inline void pd_select_polarity(int port, int polarity)
{
/* use the right comparator non inverted input for COMP1 */
- STM32_COMP_CSR = (STM32_COMP_CSR & ~STM32_COMP_CMP1INSEL_MASK)
- | STM32_COMP_CMP1EN
- | (polarity ?
- STM32_COMP_CMP1INSEL_INM4 :
+ STM32_COMP_CSR = (STM32_COMP_CSR & ~STM32_COMP_CMP1INSEL_MASK) |
+ STM32_COMP_CMP1EN |
+ (polarity ? STM32_COMP_CMP1INSEL_INM4 :
STM32_COMP_CMP1INSEL_INM6);
gpio_set_level(GPIO_USBC_POLARITY, polarity);
}
