From: Øyvind H. <go...@us...> - 2009-12-15 13:29:44
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Main OpenOCD repository". The branch, master has been updated via 4639366947427da6face9cb6954b6603eb2e2fd3 (commit) via dca173053b1ebf3e99145a3cf6ea14937bf2fa3d (commit) from d6aff79f1a5263e920d23b6b63331437fa0a6af8 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 4639366947427da6face9cb6954b6603eb2e2fd3 Author: Ãyvind Harboe <oyv...@zy...> Date: Tue Dec 15 13:24:28 2009 +0100 zy1000: keep up with command.h cleanup Signed-off-by: Ãyvind Harboe <oyv...@zy...> diff --git a/src/ecosboard.c b/src/ecosboard.c index 2e491c2..2a9950d 100644 --- a/src/ecosboard.c +++ b/src/ecosboard.c @@ -249,11 +249,21 @@ int zy1000_configuration_output_handler_log(struct command_context *context, } #ifdef CYGPKG_PROFILE_GPROF +//extern int64_t totaltime; -int eCosBoard_handle_eCosBoard_profile_command(struct command_context *cmd_ctx, char *cmd, char **args, int argc) +static int zylinjtag_Jim_Command_profile(Jim_Interp *interp, int argc, + Jim_Obj * const *argv) { - command_print(cmd_ctx, "Profiling started"); - start_profile(); + if ((argc == 2) && (strcmp(Jim_GetString(argv[1], NULL), "stats")==0)) + { +// profile_off(); + //LOG_USER("Stats %dms sleeping in select()", (int)totaltime); + } else + { + LOG_USER("Profiling started"); + start_profile(); + //totaltime = 0; + } return ERROR_OK; } @@ -1079,8 +1089,8 @@ int main(int argc, char *argv[]) return EXIT_FAILURE; #ifdef CYGPKG_PROFILE_GPROF - COMMAND_REGISTER(cmd_ctx, NULL, "ecosboard_profile", eCosBoard_handle_eCosBoard_profile_command, - COMMAND_ANY, NULL); + Jim_CreateCommand(httpstate.jim_interp, "zy1000_profile", zylinjtag_Jim_Command_profile, + NULL, NULL); #endif Jim_CreateCommand(httpstate.jim_interp, "uart", zylinjtag_Jim_Command_uart, NULL, NULL); commit dca173053b1ebf3e99145a3cf6ea14937bf2fa3d Author: Ãyvind Harboe <oyv...@zy...> Date: Tue Dec 15 13:23:07 2009 +0100 command: retire obsolete macro COMMAND_REGISTER() was only used transiently during code conversion. Signed-off-by: Ãyvind Harboe <oyv...@zy...> diff --git a/src/helper/command.h b/src/helper/command.h index aaba9b0..8a418d3 100644 --- a/src/helper/command.h +++ b/src/helper/command.h @@ -253,17 +253,6 @@ struct command_registration { struct command* register_command(struct command_context *cmd_ctx, struct command *parent, const struct command_registration *rec); -#define COMMAND_REGISTER(_cmd_ctx, _parent, _name, _handler, _mode, _help) \ - ({ \ - struct command_registration cr = { \ - .name = _name, \ - .handler = _handler, \ - .mode = _mode, \ - .help = _help, \ - }; \ - register_command(_cmd_ctx, _parent, &cr); \ - }) - /** * Register one or more commands in the specified context, as children * of @c parent (or top-level commends, if NULL). In a registration's ----------------------------------------------------------------------- Summary of changes: src/ecosboard.c | 20 +++++++++++++++----- src/helper/command.h | 11 ----------- 2 files changed, 15 insertions(+), 16 deletions(-) hooks/post-receive -- Main OpenOCD repository |