forked from auracaster/openocd
jtag: Rename 'hasidcode' to 'has_idcode'
While at it, fix some coding style issues. Change-Id: I8196045f46ce043ed0d28cb95470132b3a7de1bb Signed-off-by: Marc Schink <dev@zapb.de> Reviewed-on: https://review.openocd.org/c/openocd/+/8039 Tested-by: jenkins Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
This commit is contained in:
committed by
Antonio Borneo
parent
d3d287bf67
commit
f018cd7d90
@@ -1177,7 +1177,7 @@ static bool jtag_examine_chain_end(uint8_t *idcodes, unsigned count, unsigned ma
|
||||
static bool jtag_examine_chain_match_tap(const struct jtag_tap *tap)
|
||||
{
|
||||
|
||||
if (tap->expected_ids_cnt == 0 || !tap->hasidcode)
|
||||
if (tap->expected_ids_cnt == 0 || !tap->has_idcode)
|
||||
return true;
|
||||
|
||||
/* optionally ignore the JTAG version field - bits 28-31 of IDCODE */
|
||||
@@ -1283,13 +1283,13 @@ static int jtag_examine_chain(void)
|
||||
/* Zero for LSB indicates a device in bypass */
|
||||
LOG_INFO("TAP %s does not have valid IDCODE (idcode=0x%" PRIx32 ")",
|
||||
tap->dotted_name, idcode);
|
||||
tap->hasidcode = false;
|
||||
tap->has_idcode = false;
|
||||
tap->idcode = 0;
|
||||
|
||||
bit_count += 1;
|
||||
} else {
|
||||
/* Friendly devices support IDCODE */
|
||||
tap->hasidcode = true;
|
||||
tap->has_idcode = true;
|
||||
tap->idcode = idcode;
|
||||
jtag_examine_chain_display(LOG_LVL_INFO, "tap/device found", tap->dotted_name, idcode);
|
||||
|
||||
|
||||
@@ -100,7 +100,7 @@ int hl_interface_init_target(struct target *t)
|
||||
}
|
||||
|
||||
t->tap->priv = &hl_if;
|
||||
t->tap->hasidcode = 1;
|
||||
t->tap->has_idcode = true;
|
||||
|
||||
return ERROR_OK;
|
||||
}
|
||||
|
||||
@@ -115,7 +115,7 @@ struct jtag_tap {
|
||||
uint32_t idcode; /**< device identification code */
|
||||
/** not all devices have idcode,
|
||||
* we'll discover this during chain examination */
|
||||
bool hasidcode;
|
||||
bool has_idcode;
|
||||
|
||||
/** Array of expected identification codes */
|
||||
uint32_t *expected_ids;
|
||||
|
||||
Reference in New Issue
Block a user