target: create and use target_name()
Several of the sites now using target_type_name() really ought to be using an instance-specific name. Create a function called target_name(), accessing the instance's own (command) name. Use it in several places that really should be displaying instance-specific names. Also in several places which were already doing so, but which had no wrapper to call. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
This commit is contained in:
@@ -159,6 +159,12 @@ struct target
|
||||
long long halt_issued_time; /* Note time when halt was issued */
|
||||
};
|
||||
|
||||
/** Returns the instance-specific name of the specified target. */
|
||||
static inline const char *target_name(struct target *target)
|
||||
{
|
||||
return target->cmd_name;
|
||||
}
|
||||
|
||||
enum target_event
|
||||
{
|
||||
/* LD historical names
|
||||
|
||||
Reference in New Issue
Block a user