From d331aca296f9f793309f3759e873d9ef7ae74dda Mon Sep 17 00:00:00 2001 From: deadprogram Date: Sat, 6 May 2023 13:21:25 +0200 Subject: [PATCH] machine/rp2040: correct write block size for flash Signed-off-by: deadprogram --- src/machine/machine_rp2040_rom.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/machine/machine_rp2040_rom.go b/src/machine/machine_rp2040_rom.go index 7944bacd..b4370c77 100644 --- a/src/machine/machine_rp2040_rom.go +++ b/src/machine/machine_rp2040_rom.go @@ -195,7 +195,7 @@ func (f flashBlockDevice) Size() int64 { return int64(FlashDataEnd() - FlashDataStart()) } -const writeBlockSize = 4 +const writeBlockSize = 1 << 8 // WriteBlockSize returns the block size in which data can be written to // memory. It can be used by a client to optimize writes, non-aligned writes