]> git.sur5r.net Git - u-boot/blobdiff - common/cmd_net.c
ColdFire 54455: Fix correct boot location for atmel and intel
[u-boot] / common / cmd_net.c
index 26efc6d20656a80c0f31aa2c052cca8b0eac0661..0715fbc203ce06fc8fa2c61af5db240ec9de50b3 100644 (file)
@@ -30,7 +30,6 @@
 
 #if defined(CONFIG_CMD_NET)
 
-
 extern int do_bootm (cmd_tbl_t *, int, int, char *[]);
 
 static int netboot_common (proto_t, cmd_tbl_t *, int , char *[]);
@@ -186,18 +185,25 @@ netboot_common (proto_t proto, cmd_tbl_t *cmdtp, int argc, char *argv[])
                break;
 
        default: printf ("Usage:\n%s\n", cmdtp->usage);
+               show_boot_progress (-80);
                return 1;
        }
 
-       if ((size = NetLoop(proto)) < 0)
+       show_boot_progress (80);
+       if ((size = NetLoop(proto)) < 0) {
+               show_boot_progress (-81);
                return 1;
+       }
 
+       show_boot_progress (81);
        /* NetLoop ok, update environment */
        netboot_update_env();
 
        /* done if no file was loaded (no errors though) */
-       if (size == 0)
+       if (size == 0) {
+               show_boot_progress (-82);
                return 0;
+       }
 
        /* flush cache */
        flush_cache(load_addr, size);
@@ -210,15 +216,21 @@ netboot_common (proto_t proto, cmd_tbl_t *cmdtp, int argc, char *argv[])
 
                printf ("Automatic boot of image at addr 0x%08lX ...\n",
                        load_addr);
+               show_boot_progress (82);
                rcode = do_bootm (cmdtp, 0, 1, local_args);
        }
 
 #ifdef CONFIG_AUTOSCRIPT
        if (((s = getenv("autoscript")) != NULL) && (strcmp(s,"yes") == 0)) {
                printf("Running autoscript at addr 0x%08lX ...\n", load_addr);
+               show_boot_progress (83);
                rcode = autoscript (load_addr);
        }
 #endif
+       if (rcode < 0)
+               show_boot_progress (-83);
+       else
+               show_boot_progress (84);
        return rcode;
 }