diff options
Diffstat (limited to 'chip/stm32/flash-stm32l.c')
-rw-r--r-- | chip/stm32/flash-stm32l.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/chip/stm32/flash-stm32l.c b/chip/stm32/flash-stm32l.c index f796f4efaa..61916abf2d 100644 --- a/chip/stm32/flash-stm32l.c +++ b/chip/stm32/flash-stm32l.c @@ -314,13 +314,13 @@ int flash_physical_get_protect(int block) return 1; /* Check the active write protect status */ - return STM32_FLASH_WRPR & (1 << block); + return STM32_FLASH_WRPR & BIT(block); } int flash_physical_protect_at_boot(uint32_t new_flags) { uint32_t prot; - uint32_t mask = ((1 << WP_BANK_COUNT) - 1) << WP_BANK_OFFSET; + uint32_t mask = (BIT(WP_BANK_COUNT) - 1) << WP_BANK_OFFSET; int rv; if (new_flags & EC_FLASH_PROTECT_ALL_AT_BOOT) |