streamline and document helptext mode displays

Most commands are usable only at runtime; so don't bother saying
that, it's noise.  Moreover, tokens like EXEC are cryptic.  Be
more clear: highlight only the commands which may (also) be used
during the config stage, thus matching the docs more closely.
There are

 - Configuration commands (per documentation)
 - And also some commands that valid at *any* time.

Update the docs to note that "help" now shows this mode info.

This also highlighted a few mistakes in command configuration,
mostly commands listed as "valid at any time" which shouldn't
have been.  This just fixes ones I noted when sanity testing.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
This commit is contained in:
David Brownell
2010-01-02 15:52:35 -08:00
parent 9d167d62f2
commit b3bf1d12b2
8 changed files with 39 additions and 19 deletions

View File

@@ -834,7 +834,7 @@ static const struct command_registration armv7m_exec_command_handlers[] = {
const struct command_registration armv7m_command_handlers[] = {
{
.name = "dap",
.mode = COMMAND_ANY,
.mode = COMMAND_EXEC,
.help = "Cortex DAP command group",
.chain = armv7m_exec_command_handlers,
},

View File

@@ -2003,7 +2003,7 @@ static const struct command_registration cortex_m3_command_handlers[] = {
},
{
.name = "cortex_m3",
.mode = COMMAND_ANY,
.mode = COMMAND_EXEC,
.help = "Cortex-M3 command group",
.chain = cortex_m3_exec_command_handlers,
},

View File

@@ -4866,7 +4866,7 @@ static const struct command_registration target_exec_command_handlers[] = {
{
.name = "fast_load",
.handler = &handle_fast_load_command,
.mode = COMMAND_ANY,
.mode = COMMAND_EXEC,
.help = "loads active fast load image to current target "
"- mainly for profiling purposes",
},

View File

@@ -177,7 +177,7 @@ static const struct command_registration trace_exec_command_handlers[] = {
static const struct command_registration trace_command_handlers[] = {
{
.name = "trace",
.mode = COMMAND_ANY,
.mode = COMMAND_EXEC,
.help = "trace command group",
.chain = trace_exec_command_handlers,
},