target: arc: rewrite command 'arc add-reg' as COMMAND_HANDLER
While there, fix some coding style error and remove the now unused function jim_arc_read_reg_name_field() and the macro JIM_CHECK_RETVAL(). Change-Id: I140b4b929978b2936f2310e0b7d1735ba726c517 Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com> Reviewed-on: https://review.openocd.org/c/openocd/+/7426 Tested-by: jenkins Reviewed-by: Evgeniy Didin <didin@synopsys.com>
This commit is contained in:
@@ -253,16 +253,6 @@ struct arc_common {
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define JIM_CHECK_RETVAL(action) \
|
||||
do { \
|
||||
int __retval = (action); \
|
||||
if (__retval != JIM_OK) { \
|
||||
LOG_DEBUG("error while calling \"%s\"", \
|
||||
# action); \
|
||||
return __retval; \
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
static inline struct arc_common *target_to_arc(struct target *target)
|
||||
{
|
||||
return target->arch_info;
|
||||
|
||||
Reference in New Issue
Block a user