This used to be done inside ao_boot_check_chain or ao_boot_check_pin,
but it made more sense to have it done in _start instead. stm and lpc
were adjusted, but stmf0 and stm32f4 were missed.
This caused boards using this process to wedge in the boot loader.
Signed-off-by: Keith Packard <keithp@keithp.com>
#ifdef AO_BOOT_CHAIN
if (ao_boot_check_chain()) {
#ifdef AO_BOOT_PIN
- ao_boot_check_pin();
+ if (ao_boot_check_pin())
#endif
+ {
+ ao_boot_chain(AO_BOOT_APPLICATION_BASE);
+ }
}
#endif
/* Enable FPU */
#if AO_BOOT_CHAIN
if (ao_boot_check_chain()) {
#if AO_BOOT_PIN
- ao_boot_check_pin();
+ if (ao_boot_check_pin())
#endif
+ {
+ ao_boot_chain(AO_BOOT_APPLICATION_BASE);
+ }
}
#endif
/* Turn on syscfg */