From: Andrew Murray <[email protected]>

This patch adds bootgraph instrumentation for all U_BOOT_CMDs where the
HUSH parser is not used. The patch also adds instrumentation for the
common boot delay.
---
Changes for v2:
        - Use improved DO_INITCALL_RET macro

Signed-off-by: Andrew Murray <[email protected]>
---
 common/main.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/common/main.c b/common/main.c
index 2730c6f..bf95463 100644
--- a/common/main.c
+++ b/common/main.c
@@ -376,7 +376,7 @@ void main_loop (void)
 
        debug ("### main_loop: bootcmd=\"%s\"\n", s ? s : "<UNDEFINED>");
 
-       if (bootdelay >= 0 && s && !abortboot (bootdelay)) {
+       if (bootdelay >= 0 && s && !DO_INITCALL_RET(abortboot, bootdelay)) {
 # ifdef CONFIG_AUTOBOOT_KEYED
                int prev = disable_ctrlc(1);    /* disable Control C checking */
 # endif
@@ -385,11 +385,11 @@ void main_loop (void)
                run_command (s, 0);
 # else
                parse_string_outer(s, FLAG_PARSE_SEMICOLON |
-                                   FLAG_EXIT_FROM_LOOP);
+                           FLAG_EXIT_FROM_LOOP);
 # endif
 
 # ifdef CONFIG_AUTOBOOT_KEYED
-               disable_ctrlc(prev);    /* restore Control C checking */
+                       disable_ctrlc(prev);    /* restore Control C checking */
 # endif
        }
 
@@ -1371,7 +1371,7 @@ int run_command (const char *cmd, int flag)
 #endif
 
                /* OK - call function to do the command */
-               if ((cmdtp->cmd) (cmdtp, flag, argc, argv) != 0) {
+               if (DO_INITCALL_RET(cmdtp->cmd, cmdtp, flag, argc, argv) != 0) {
                        rc = -1;
                }
 
-- 
1.7.4.1

_______________________________________________
U-Boot mailing list
[email protected]
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to