diff options
author | Gerrit <chrome-bot@google.com> | 2012-05-30 11:31:43 -0700 |
---|---|---|
committer | Gerrit Code Review <gerrit@gerrit.golo.chromium.org> | 2012-05-30 11:31:43 -0700 |
commit | aad3f858a436bc6c763d4ddf8a49fad6465302da (patch) | |
tree | e6a526561d75700487b33b29e6d1f37a983b0f90 | |
parent | 6654374f31f562dfd0012f83ca4d58735458e4b2 (diff) | |
parent | ef7557b4fd1a6a889d9918b2811567af216ebaf3 (diff) | |
download | chrome-ec-aad3f858a436bc6c763d4ddf8a49fad6465302da.tar.gz |
Merge "stm32f: update flash write size"
-rw-r--r-- | chip/stm32/flash-stm32f100.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/chip/stm32/flash-stm32f100.c b/chip/stm32/flash-stm32f100.c index 583b4225ab..ba8d7dd8bf 100644 --- a/chip/stm32/flash-stm32f100.c +++ b/chip/stm32/flash-stm32f100.c @@ -13,7 +13,7 @@ #include "util.h" #include "watchdog.h" -#define FLASH_WRITE_BYTES 2 +#define FLASH_WRITE_BYTES 64 #define FLASH_ERASE_BYTES 1024 #define FLASH_PROTECT_BYTES 4096 @@ -141,7 +141,7 @@ int flash_physical_write(int offset, int size, const char *data) STM32_FLASH_CR |= (1<<0); - for ( ; size > 0; size -= FLASH_WRITE_BYTES) { + for ( ; size > 0; size -= sizeof(*data16)) { #ifdef CONFIG_TASK_WATCHDOG /* Reload the watchdog timer to avoid watchdog reset when doing * long writing with interrupt disabled. |