fix long standing bug where the last pages of NVM were not erased

properly.
This commit is contained in:
Mariano Alvira 2010-06-08 16:07:06 -04:00
parent 36361e1eb0
commit beb75cd355
2 changed files with 3 additions and 3 deletions

View file

@ -50,8 +50,8 @@
#define uart_init uart1_init #define uart_init uart1_init
/* nvm-read */ /* nvm-read */
#define READ_ADDR 0x1E000 #define READ_ADDR 0x1f000
#define READ_NBYTES 8 #define READ_NBYTES 1024
/* nvm-write */ /* nvm-write */
#define WRITE_NBYTES 8 #define WRITE_NBYTES 8

View file

@ -101,7 +101,7 @@ void main(void) {
dbg_putstr("\n\r"); dbg_putstr("\n\r");
/* erase the flash */ /* erase the flash */
err = nvm_erase(gNvmInternalInterface_c, type, 0x4fffffff); err = nvm_erase(gNvmInternalInterface_c, type, 0x7fffffff);
dbg_putstr("nvm_erase returned: 0x"); dbg_putstr("nvm_erase returned: 0x");
dbg_put_hex(err); dbg_put_hex(err);