Skip to content

Commit b34d055

Browse files
pabigotMaureenHelm
authored andcommitted
drivers: flash: spi_nor: correct log message
Flash size is specified in bits by SFDP and devicetree, but the stored flash size is in bytes. Correct the divisor. Signed-off-by: Peter Bigot <[email protected]>
1 parent db5270b commit b34d055

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/flash/spi_nor.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -647,7 +647,7 @@ static int spi_nor_process_bfp(const struct device *dev,
647647
struct jesd216_erase_type *etp = data->erase_types;
648648
const size_t flash_size = jesd216_bfp_density(bfp) / 8U;
649649

650-
LOG_INF("%s: %u MiBy flash", dev->name, (uint32_t)(flash_size >> 23));
650+
LOG_INF("%s: %u MiBy flash", dev->name, (uint32_t)(flash_size >> 20));
651651

652652
/* Copy over the erase types, preserving their order. (The
653653
* Sector Map Parameter table references them by index.)

0 commit comments

Comments
 (0)