target: add debug_reason_name()
Provide and use debug_reason_name() instead of expecting targets to call Jim_Nvp_value2name_simple(). Less dependency on Jim, and the code becomes more clear too. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
This commit is contained in:
@@ -91,8 +91,6 @@ enum target_debug_reason
|
||||
DBG_REASON_UNDEFINED = 6
|
||||
};
|
||||
|
||||
extern const Jim_Nvp nvp_target_debug_reason[];
|
||||
|
||||
enum target_endianess
|
||||
{
|
||||
TARGET_ENDIAN_UNKNOWN = 0,
|
||||
@@ -165,6 +163,8 @@ static inline const char *target_name(struct target *target)
|
||||
return target->cmd_name;
|
||||
}
|
||||
|
||||
const char *debug_reason_name(struct target *t);
|
||||
|
||||
enum target_event
|
||||
{
|
||||
/* LD historical names
|
||||
|
||||
Reference in New Issue
Block a user