The first time, the flash memory is full of garbage. It needs to be marked as empty.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
5
flash.c
5
flash.c
@@ -130,9 +130,8 @@ flash_do_storage_init (const uint8_t **p_do_start, const uint8_t **p_do_end)
|
|||||||
|
|
||||||
if (gen0 == 0xffff && gen1 == 0xffff)
|
if (gen0 == 0xffff && gen1 == 0xffff)
|
||||||
{
|
{
|
||||||
/* It's terminated. */
|
gen0 = 0x0000;
|
||||||
*p_do_start = *p_do_end = NULL;
|
*gen0_p = gen0;
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gen0 == 0xffff)
|
if (gen0 == 0xffff)
|
||||||
|
|||||||
Reference in New Issue
Block a user