rp: Fixed another clang-tidy warning

This commit is contained in:
dragonmux 2022-07-31 16:44:03 +01:00 committed by Piotr Esden-Tempski
parent 7266e3cf54
commit 6288d5884d
1 changed files with 3 additions and 3 deletions

View File

@ -467,9 +467,9 @@ static uint32_t rp_get_flash_length(target *t)
uint32_t mirrorsec[16]; uint32_t mirrorsec[16];
while (size > FLASHSIZE_4K_SECTOR) { while (size > FLASHSIZE_4K_SECTOR) {
target_mem_read(t, mirrorsec, XIP_FLASH_START + size, sizeof(bootsec)); target_mem_read(t, mirrorsec, XIP_FLASH_START + size, sizeof(bootsec));
if (memcmp(bootsec, mirrorsec, sizeof(bootsec))) if (memcmp(bootsec, mirrorsec, sizeof(bootsec)) != 0)
return size << 1; return size << 1U;
size >>= 1; size >>= 1U;
} }
} }