Oops. When converting from ao_storage to ao_config, I accidentally had
the flight erase log overwriting the config block.
Signed-off-by: Keith Packard <keithp@keithp.com>
static uint32_t
ao_log_erase_pos(uint8_t i)
{
static uint32_t
ao_log_erase_pos(uint8_t i)
{
- return i * sizeof (struct ao_log_erase);
+ return i * sizeof (struct ao_log_erase) + AO_CONFIG_MAX_SIZE;
/* Storage unit size - device reads and writes must be within blocks of this size. Usually 256 bytes. */
extern __pdata uint16_t ao_storage_unit;
/* Storage unit size - device reads and writes must be within blocks of this size. Usually 256 bytes. */
extern __pdata uint16_t ao_storage_unit;
-#define AO_STORAGE_ERASE_LOG (ao_storage_config + AO_CONFIG_MAX_SIZE)
-
/* Initialize above values. Can only be called once the OS is running */
void
ao_storage_setup(void) __reentrant;
/* Initialize above values. Can only be called once the OS is running */
void
ao_storage_setup(void) __reentrant;