mirror of https://github.com/wolfSSL/wolfBoot.git
SAM E51: hal_flash_erase bugfix
Increment the address when erasing multiple pages.pull/413/head
parent
c2388cd142
commit
32057f1fa0
|
@ -391,6 +391,7 @@ int RAMFUNCTION hal_flash_erase(uint32_t address, int len)
|
||||||
while(!(NVMCTRL_INTFLAG & NVMCTRL_INTFLAG_CMD_DONE))
|
while(!(NVMCTRL_INTFLAG & NVMCTRL_INTFLAG_CMD_DONE))
|
||||||
;
|
;
|
||||||
len -= WOLFBOOT_SECTOR_SIZE;
|
len -= WOLFBOOT_SECTOR_SIZE;
|
||||||
|
address += WOLFBOOT_SECTOR_SIZE;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue