]> Git Repo - J-u-boot.git/blobdiff - common/main.c
usb: onboard-hub: Fix the return values of regulator APIs
[J-u-boot.git] / common / main.c
index 3f5214fd44b8643199e9a6bd69a2711d833c5049..b0b6e74f5d3d385df0be498240d9001dfa2c5136 100644 (file)
@@ -6,13 +6,15 @@
 
 /* #define     DEBUG   */
 
-#include <common.h>
 #include <autoboot.h>
+#include <button.h>
 #include <bootstage.h>
+#include <bootstd.h>
 #include <cli.h>
 #include <command.h>
 #include <console.h>
 #include <env.h>
+#include <fdtdec.h>
 #include <init.h>
 #include <net.h>
 #include <version_string.h>
@@ -54,8 +56,13 @@ void main_loop(void)
        if (IS_ENABLED(CONFIG_UPDATE_TFTP))
                update_tftp(0UL, NULL, NULL);
 
-       if (IS_ENABLED(CONFIG_EFI_CAPSULE_ON_DISK_EARLY))
-               efi_launch_capsules();
+       if (IS_ENABLED(CONFIG_EFI_CAPSULE_ON_DISK_EARLY)) {
+               /* efi_init_early() already called */
+               if (efi_init_obj_list() == EFI_SUCCESS)
+                       efi_launch_capsules();
+       }
+
+       process_button_cmds();
 
        s = bootdelay_process();
        if (cli_process_fdt(&s))
@@ -63,6 +70,16 @@ void main_loop(void)
 
        autoboot_command(s);
 
+       /* if standard boot if enabled, assume that it will be able to boot */
+       if (IS_ENABLED(CONFIG_BOOTSTD_PROG)) {
+               int ret;
+
+               ret = bootstd_prog_boot();
+               printf("Standard boot failed (err=%dE)\n", ret);
+               panic("Failed to boot");
+       }
+
        cli_loop();
+
        panic("No CLI available");
 }
This page took 0.026122 seconds and 4 git commands to generate.