slinky - Slight rearrangement of loader init.
This change does not fix any observable issue.  It is only made to
reinforce the preferred control flow for the split image setup.  The
loader should jump into the app at the very end of main(), where the OS
would normally get started.
@@ -303,6 +303,11 @@ main(int argc, char **argv)
log_reboot(hal_reset_cause());
+ init_tasks();
+
+ /* If this app is acting as the loader in a split image setup, jump into
+ * the second stage application instead of starting the OS.
+ */
#if MYNEWT_VAL(SPLIT_LOADER)
{
void *entry;
@@ -313,8 +318,6 @@ main(int argc, char **argv)
}
#endif
- init_tasks();
-
os_start();
/* os start should never return. If it does, this should be an error */
