diff options
author | wdenk <wdenk> | 2003-07-01 21:06:45 +0000 |
---|---|---|
committer | wdenk <wdenk> | 2003-07-01 21:06:45 +0000 |
commit | 0d4983930a3559be92452761cfa268ee9d0f2773 (patch) | |
tree | cfb77c1274a959cde007a7ac4e18b4b0d67bd253 /common/command.c | |
parent | b37c7e5e5c3c80c68f49a31c4308b159bb5bda1a (diff) | |
download | u-boot-imx-0d4983930a3559be92452761cfa268ee9d0f2773.zip u-boot-imx-0d4983930a3559be92452761cfa268ee9d0f2773.tar.gz u-boot-imx-0d4983930a3559be92452761cfa268ee9d0f2773.tar.bz2 |
Patch by Kenneth Johansson, 30 Jun 2003:
get rid of MK_CMD_ENTRY macro; update doc/README.command
Diffstat (limited to 'common/command.c')
-rw-r--r-- | common/command.c | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/common/command.c b/common/command.c index 9a982b8..dfec9c1 100644 --- a/common/command.c +++ b/common/command.c @@ -36,8 +36,8 @@ do_version (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) return 0; } -cmd_tbl_t U_BOOT_CMD(VERS) = MK_CMD_ENTRY( - "version", 1, 1, do_version, +U_BOOT_CMD( + version, 1, 1, do_version, "version - print monitor version\n", NULL ); @@ -67,8 +67,8 @@ do_echo (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) return 0; } -cmd_tbl_t U_BOOT_CMD(ECHO) = MK_CMD_ENTRY( - "echo", CFG_MAXARGS, 1, do_echo, +U_BOOT_CMD( + echo, CFG_MAXARGS, 1, do_echo, "echo - echo args to console\n", "[args..]\n" " - echo args to console; \\c suppresses newline\n" @@ -158,8 +158,8 @@ int do_help (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[]) } -cmd_tbl_t U_BOOT_CMD(HELP) = MK_CMD_ENTRY( - "help", CFG_MAXARGS, 1, do_help, +U_BOOT_CMD( + help, CFG_MAXARGS, 1, do_help, "help - print online help\n", "[command ...]\n" " - show help information (for 'command')\n" @@ -169,11 +169,19 @@ cmd_tbl_t U_BOOT_CMD(HELP) = MK_CMD_ENTRY( "'help' with one or more command names as arguments.\n" ); -cmd_tbl_t U_BOOT_CMD(QUES) = MK_CMD_ENTRY( +/* This do not ust the U_BOOT_CMD macro as ? can't be used in symbol names */ +#ifdef CFG_LONGHELP +cmd_tbl_t __u_boot_cmd_question_mark Struct_Section = { "?", CFG_MAXARGS, 1, do_help, "? - alias for 'help'\n", NULL -); +}; +#else +cmd_tbl_t __u_boot_cmd_question_mark Struct_Section = { + "?", CFG_MAXARGS, 1, do_help, + "? - alias for 'help'\n" +}; +#endif /* CFG_LONGHELP */ /*************************************************************************** * find command table entry for a command |