diff options
Diffstat (limited to 'board/servo_v4/usb_pd_config.h')
-rw-r--r-- | board/servo_v4/usb_pd_config.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/board/servo_v4/usb_pd_config.h b/board/servo_v4/usb_pd_config.h index 56c8d3aa02..41963a8360 100644 --- a/board/servo_v4/usb_pd_config.h +++ b/board/servo_v4/usb_pd_config.h @@ -83,7 +83,7 @@ static inline void spi_enable_clock(int port) * EXTI line 22 is connected to the CMP2 output, * CHG uses CMP2, and DUT uses CMP1. */ -#define EXTI_COMP_MASK(p) ((p) ? (1<<21) : (1 << 22)) +#define EXTI_COMP_MASK(p) ((p) ? (1<<21) : BIT(22)) #define IRQ_COMP STM32_IRQ_COMP /* triggers packet detection on comparator falling edge */ @@ -119,12 +119,12 @@ static inline void pd_tx_spi_reset(int port) { if (port == 0) { /* Reset SPI1 */ - STM32_RCC_APB2RSTR |= (1 << 12); - STM32_RCC_APB2RSTR &= ~(1 << 12); + STM32_RCC_APB2RSTR |= BIT(12); + STM32_RCC_APB2RSTR &= ~BIT(12); } else { /* Reset SPI2 */ - STM32_RCC_APB1RSTR |= (1 << 14); - STM32_RCC_APB1RSTR &= ~(1 << 14); + STM32_RCC_APB1RSTR |= BIT(14); + STM32_RCC_APB1RSTR &= ~BIT(14); } } |