diff options
author | Paul Fertser <fercerpav@gmail.com> | 2019-04-01 04:37:05 +0200 |
---|---|---|
committer | Tomas Vanek <vanekt@fbl.cz> | 2019-05-14 19:34:29 +0100 |
commit | 6a453e5cf0adc4d19378e953122ca69efcf32b6d (patch) | |
tree | d18ba19530a7bd26e97f80ecd4b4c89a67ba8953 | |
parent | c104617584cfe14c0c859227f6aad51d48d74d63 (diff) |
target/arm966e: change prototype of arm966e_verify_pointer()
To prepare for handling TCL return values consistently, all calls
to command_print/command_print_sameline should be ready to switch
to CMD as first parameter.
Change prototype of arm966e_verify_pointer() to pass CMD instead
of CMD_CTX.
This change was part of http://openocd.zylin.com/1815 from Paul
Fertser and has been extracted and rebased to simplify the review.
Change-Id: I92745591256ad56a588b6386842028e0b18dec96
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5058
Tested-by: jenkins
-rw-r--r-- | src/target/arm966e.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/target/arm966e.c b/src/target/arm966e.c index c9d7f01a..98c62745 100644 --- a/src/target/arm966e.c +++ b/src/target/arm966e.c @@ -56,11 +56,11 @@ static int arm966e_target_create(struct target *target, Jim_Interp *interp) return arm966e_init_arch_info(target, arm966e, target->tap); } -static int arm966e_verify_pointer(struct command_context *cmd_ctx, +static int arm966e_verify_pointer(struct command_invocation *cmd, struct arm966e_common *arm966e) { if (arm966e->common_magic != ARM966E_COMMON_MAGIC) { - command_print(cmd_ctx, "target is not an ARM966"); + command_print(cmd->ctx, "target is not an ARM966"); return ERROR_TARGET_INVALID; } return ERROR_OK; @@ -170,7 +170,7 @@ COMMAND_HANDLER(arm966e_handle_cp15_command) struct target *target = get_current_target(CMD_CTX); struct arm966e_common *arm966e = target_to_arm966(target); - retval = arm966e_verify_pointer(CMD_CTX, arm966e); + retval = arm966e_verify_pointer(CMD, arm966e); if (retval != ERROR_OK) return retval; |