jtag: drop useless typedef tap_state_t

No need to use a typedef for an enum.
Drop it.

Change-Id: I9eb2dc4f926671c5bb44e61453d92880e3036848
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/8709
Tested-by: jenkins
Reviewed-by: zapb <dev@zapb.de>
This commit is contained in:
Antonio Borneo
2025-01-10 17:05:29 +01:00
parent 0d1932520b
commit 4895a556fa
46 changed files with 232 additions and 232 deletions

View File

@@ -111,10 +111,10 @@ TDO (1);
static int xsvf_fd;
/* map xsvf tap state to an openocd "tap_state_t" */
static tap_state_t xsvf_to_tap(int xsvf_state)
/* map xsvf tap state to an openocd "enum tap_state" */
static enum tap_state xsvf_to_tap(int xsvf_state)
{
tap_state_t ret;
enum tap_state ret;
switch (xsvf_state) {
case XSV_RESET:
@@ -196,16 +196,16 @@ COMMAND_HANDLER(handle_xsvf_command)
int xruntest = 0; /* number of TCK cycles OR *microseconds */
int xrepeat = 0; /* number of retries */
tap_state_t xendir = TAP_IDLE; /* see page 8 of the SVF spec, initial
enum tap_state xendir = TAP_IDLE; /* see page 8 of the SVF spec, initial
*xendir to be TAP_IDLE */
tap_state_t xenddr = TAP_IDLE;
enum tap_state xenddr = TAP_IDLE;
uint8_t opcode;
uint8_t uc = 0;
long file_offset = 0;
int loop_count = 0;
tap_state_t loop_state = TAP_IDLE;
enum tap_state loop_state = TAP_IDLE;
int loop_clocks = 0;
int loop_usecs = 0;
@@ -216,7 +216,7 @@ COMMAND_HANDLER(handle_xsvf_command)
int verbose = 1;
bool collecting_path = false;
tap_state_t path[XSTATE_MAX_PATH];
enum tap_state path[XSTATE_MAX_PATH];
unsigned int pathlen = 0;
/* a flag telling whether to clock TCK during waits,
@@ -272,7 +272,7 @@ COMMAND_HANDLER(handle_xsvf_command)
* or terminate a path.
*/
if (collecting_path) {
tap_state_t mystate;
enum tap_state mystate;
switch (opcode) {
case XCOMMENT:
@@ -455,7 +455,7 @@ COMMAND_HANDLER(handle_xsvf_command)
* will be skipped entirely if xrepeat is set to zero.
*/
static tap_state_t exception_path[] = {
static enum tap_state exception_path[] = {
TAP_DREXIT2,
TAP_DRSHIFT,
TAP_DREXIT1,
@@ -563,7 +563,7 @@ COMMAND_HANDLER(handle_xsvf_command)
case XSTATE:
{
tap_state_t mystate;
enum tap_state mystate;
if (read(xsvf_fd, &uc, 1) < 0) {
do_abort = 1;
@@ -654,7 +654,7 @@ COMMAND_HANDLER(handle_xsvf_command)
uint8_t short_buf[2];
uint8_t *ir_buf;
int bitcount;
tap_state_t my_end_state = xruntest ? TAP_IDLE : xendir;
enum tap_state my_end_state = xruntest ? TAP_IDLE : xendir;
if (opcode == XSIR) {
/* one byte bitcount */
@@ -744,8 +744,8 @@ COMMAND_HANDLER(handle_xsvf_command)
uint8_t end;
uint8_t delay_buf[4];
tap_state_t wait_state;
tap_state_t end_state;
enum tap_state wait_state;
enum tap_state end_state;
int delay;
if (read(xsvf_fd, &wait_local, 1) < 0
@@ -788,8 +788,8 @@ COMMAND_HANDLER(handle_xsvf_command)
uint8_t usecs_buf[4];
uint8_t wait_local;
uint8_t end;
tap_state_t wait_state;
tap_state_t end_state;
enum tap_state wait_state;
enum tap_state end_state;
int clock_count;
int usecs;