target_type_t -> struct target_type
authorZachary T Welch <zw@superlucidity.net>
Fri, 13 Nov 2009 17:52:20 +0000 (09:52 -0800)
committerZachary T Welch <zw@superlucidity.net>
Fri, 13 Nov 2009 19:58:13 +0000 (11:58 -0800)
Remove misleading typedef and redundant suffix from struct target_type.

18 files changed:
src/ecosboard.c
src/target/arm11.c
src/target/arm720t.c
src/target/arm7tdmi.c
src/target/arm920t.c
src/target/arm926ejs.c
src/target/arm966e.c
src/target/arm9tdmi.c
src/target/avrt.c
src/target/cortex_a8.c
src/target/cortex_m3.c
src/target/fa526.c
src/target/feroceon.c
src/target/mips_m4k.c
src/target/target.c
src/target/target.h
src/target/target_type.h
src/target/xscale.c

index 8d85fe61bcd24f70b05758767e513650fdeef97f..455c93c05c72acbd4863621c777ed4580caac202 100644 (file)
@@ -115,7 +115,7 @@ char hwaddr[512];
 
 
 extern struct flash_driver *flash_drivers[];
 
 
 extern struct flash_driver *flash_drivers[];
-extern target_type_t *target_types[];
+extern struct target_type *target_types[];
 
 #ifdef CYGPKG_PROFILE_GPROF
 #include <cyg/profile/profile.h>
 
 #ifdef CYGPKG_PROFILE_GPROF
 #include <cyg/profile/profile.h>
index 42c33af78c2b35252afe86489bfa3a5567e95d8f..22925c8e86dd948752a08a33e6f5cb53fda83231 100644 (file)
@@ -2197,7 +2197,7 @@ COMMAND_HANDLER(arm11_handle_etmw)
 
 #define ARM11_HANDLER(x)       .x = arm11_##x
 
 
 #define ARM11_HANDLER(x)       .x = arm11_##x
 
-target_type_t arm11_target = {
+struct target_type arm11_target = {
                .name = "arm11",
 
                ARM11_HANDLER(poll),
                .name = "arm11",
 
                ARM11_HANDLER(poll),
index 8ef7114e637eecb4644f93f4981e58db0ee92a02..b258e2f9ce440e994f523f51319bcc5075c75713 100644 (file)
@@ -510,7 +510,7 @@ static int arm720t_register_commands(struct command_context_s *cmd_ctx)
 }
 
 /** Holds methods for ARM720 targets. */
 }
 
 /** Holds methods for ARM720 targets. */
-target_type_t arm720t_target =
+struct target_type arm720t_target =
 {
        .name = "arm720t",
 
 {
        .name = "arm720t",
 
index d1509cbb68a291689f78d6007f31a76df2e4b329..aea012dc079c2e24d8652152c355a4d2ad1dec0c 100644 (file)
@@ -753,7 +753,7 @@ static int arm7tdmi_target_create(struct target_s *target, Jim_Interp *interp)
 }
 
 /** Holds methods for ARM7TDMI targets. */
 }
 
 /** Holds methods for ARM7TDMI targets. */
-target_type_t arm7tdmi_target =
+struct target_type arm7tdmi_target =
 {
        .name = "arm7tdmi",
 
 {
        .name = "arm7tdmi",
 
index 2fe50a132fc42f9d459944f1a27d2b654bdb5a07..32f4a2fff057be81fe187c11d95cb68bc36b6288 100644 (file)
@@ -1380,7 +1380,7 @@ int arm920t_register_commands(struct command_context_s *cmd_ctx)
 }
 
 /** Holds methods for ARM920 targets. */
 }
 
 /** Holds methods for ARM920 targets. */
-target_type_t arm920t_target =
+struct target_type arm920t_target =
 {
        .name = "arm920t",
 
 {
        .name = "arm920t",
 
index 9ae19a878e0d342252519dc65ae9b10d75f7f524..fd8e0b6a33c8049bd6c3c07d1ce6a4c924368368 100644 (file)
@@ -842,7 +842,7 @@ int arm926ejs_register_commands(struct command_context_s *cmd_ctx)
 }
 
 /** Holds methods for ARM926 targets. */
 }
 
 /** Holds methods for ARM926 targets. */
-target_type_t arm926ejs_target =
+struct target_type arm926ejs_target =
 {
        .name = "arm926ejs",
 
 {
        .name = "arm926ejs",
 
index dee9f612ad18609cd9dc632202ed1eb2c0e966c3..7c46f0fd57602d7fd369cf227904b6b0761ef776 100644 (file)
@@ -233,7 +233,7 @@ int arm966e_register_commands(struct command_context_s *cmd_ctx)
 }
 
 /** Holds methods for ARM966 targets. */
 }
 
 /** Holds methods for ARM966 targets. */
-target_type_t arm966e_target =
+struct target_type arm966e_target =
 {
        .name = "arm966e",
 
 {
        .name = "arm966e",
 
index c670c454e06d202f95353d02b9414ded40c93563..1edb6264c06dc50e3f25bbd86514f08436d1b51f 100644 (file)
@@ -953,7 +953,7 @@ int arm9tdmi_register_commands(struct command_context_s *cmd_ctx)
 }
 
 /** Holds methods for ARM9TDMI targets. */
 }
 
 /** Holds methods for ARM9TDMI targets. */
-target_type_t arm9tdmi_target =
+struct target_type arm9tdmi_target =
 {
        .name = "arm9tdmi",
 
 {
        .name = "arm9tdmi",
 
index d7c7623d848d90c1e7dc42355fb4c87debbab536..ad22c99d11bcb920e32b70a03ef00deb21a1be9c 100644 (file)
@@ -59,7 +59,7 @@ int mcu_write_ir_u32(struct jtag_tap *tap, uint32_t *ir_in, uint32_t ir_out, int
 int mcu_write_dr_u32(struct jtag_tap *tap, uint32_t *ir_in, uint32_t ir_out, int dr_len, int rti);
 int mcu_execute_queue(void);
 
 int mcu_write_dr_u32(struct jtag_tap *tap, uint32_t *ir_in, uint32_t ir_out, int dr_len, int rti);
 int mcu_execute_queue(void);
 
-target_type_t avr_target =
+struct target_type avr_target =
 {
        .name = "avr",
 
 {
        .name = "avr",
 
index e1bd2e3241e14f914df3a133c652d274cb1afd92..f92531152be3c8627cc27f871f178bff74ea28c7 100644 (file)
@@ -1569,7 +1569,7 @@ static int cortex_a8_register_commands(struct command_context_s *cmd_ctx)
        return retval;
 }
 
        return retval;
 }
 
-target_type_t cortexa8_target = {
+struct target_type cortexa8_target = {
        .name = "cortex_a8",
 
        .poll = cortex_a8_poll,
        .name = "cortex_a8",
 
        .poll = cortex_a8_poll,
index bbdc85a24a83dd5df1c9ad2f3a80f8c8e47afb19..9f9016d2ca0a79f9b939aa74c1ec651b5e040ea1 100644 (file)
@@ -1951,7 +1951,7 @@ static int cortex_m3_register_commands(struct command_context_s *cmd_ctx)
        return retval;
 }
 
        return retval;
 }
 
-target_type_t cortexm3_target =
+struct target_type cortexm3_target =
 {
        .name = "cortex_m3",
 
 {
        .name = "cortex_m3",
 
index 3b884c69d74a7bedac8984e9583dde71b01d14e6..d9b89f2a4c3969d8ea4cb8a6177e1679157e4ec9 100644 (file)
@@ -358,7 +358,7 @@ static int fa526_target_create(struct target_s *target, Jim_Interp *interp)
 }
 
 /** Holds methods for FA526 targets. */
 }
 
 /** Holds methods for FA526 targets. */
-target_type_t fa526_target =
+struct target_type fa526_target =
 {
        .name = "fa526",
 
 {
        .name = "fa526",
 
index cf034c428963a9011f3e077e9a41d5629a1d66a6..73292e1077d9105ec9a2bc90a9d73ec7e1b002d3 100644 (file)
@@ -674,7 +674,7 @@ int feroceon_examine(struct target_s *target)
        return ERROR_OK;
 }
 
        return ERROR_OK;
 }
 
-target_type_t feroceon_target =
+struct target_type feroceon_target =
 {
        .name = "feroceon",
 
 {
        .name = "feroceon",
 
@@ -712,7 +712,7 @@ target_type_t feroceon_target =
        .examine = feroceon_examine,
 };
 
        .examine = feroceon_examine,
 };
 
-target_type_t dragonite_target =
+struct target_type dragonite_target =
 {
        .name = "dragonite",
 
 {
        .name = "dragonite",
 
index 095260c3db99a97f78b6483beb034a2a715d9b5a..9213ae0c622ebe80dfd670dc0fe3b620d927e476 100644 (file)
@@ -48,7 +48,7 @@ int mips_m4k_assert_reset(target_t *target);
 int mips_m4k_deassert_reset(target_t *target);
 int mips_m4k_checksum_memory(target_t *target, uint32_t address, uint32_t size, uint32_t *checksum);
 
 int mips_m4k_deassert_reset(target_t *target);
 int mips_m4k_checksum_memory(target_t *target, uint32_t address, uint32_t size, uint32_t *checksum);
 
-target_type_t mips_m4k_target =
+struct target_type mips_m4k_target =
 {
        .name = "mips_m4k",
 
 {
        .name = "mips_m4k",
 
index df8496f576333cc14899b6703a7253437173a3af..16497b4527cc07caa9d3ec992367942dc3d731bd 100644 (file)
@@ -49,23 +49,23 @@ static int target_array2mem(Jim_Interp *interp, target_t *target, int argc, Jim_
 static int target_mem2array(Jim_Interp *interp, target_t *target, int argc, Jim_Obj *const *argv);
 
 /* targets */
 static int target_mem2array(Jim_Interp *interp, target_t *target, int argc, Jim_Obj *const *argv);
 
 /* targets */
-extern target_type_t arm7tdmi_target;
-extern target_type_t arm720t_target;
-extern target_type_t arm9tdmi_target;
-extern target_type_t arm920t_target;
-extern target_type_t arm966e_target;
-extern target_type_t arm926ejs_target;
-extern target_type_t fa526_target;
-extern target_type_t feroceon_target;
-extern target_type_t dragonite_target;
-extern target_type_t xscale_target;
-extern target_type_t cortexm3_target;
-extern target_type_t cortexa8_target;
-extern target_type_t arm11_target;
-extern target_type_t mips_m4k_target;
-extern target_type_t avr_target;
-
-target_type_t *target_types[] =
+extern struct target_type arm7tdmi_target;
+extern struct target_type arm720t_target;
+extern struct target_type arm9tdmi_target;
+extern struct target_type arm920t_target;
+extern struct target_type arm966e_target;
+extern struct target_type arm926ejs_target;
+extern struct target_type fa526_target;
+extern struct target_type feroceon_target;
+extern struct target_type dragonite_target;
+extern struct target_type xscale_target;
+extern struct target_type cortexm3_target;
+extern struct target_type cortexa8_target;
+extern struct target_type arm11_target;
+extern struct target_type mips_m4k_target;
+extern struct target_type avr_target;
+
+struct target_type *target_types[] =
 {
        &arm7tdmi_target,
        &arm9tdmi_target,
 {
        &arm7tdmi_target,
        &arm9tdmi_target,
@@ -760,7 +760,7 @@ int target_init(struct command_context_s *cmd_ctx)
        int retval;
 
        for (target = all_targets; target; target = target->next) {
        int retval;
 
        for (target = all_targets; target; target = target->next) {
-               struct target_type_s *type = target->type;
+               struct target_type *type = target->type;
 
                target_reset_examined(target);
                if (target->type->examine == NULL)
 
                target_reset_examined(target);
                if (target->type->examine == NULL)
@@ -4290,9 +4290,9 @@ static int target_create(Jim_GetOptInfo *goi)
        target->target_number = new_target_number();
 
        /* allocate memory for each unique target type */
        target->target_number = new_target_number();
 
        /* allocate memory for each unique target type */
-       target->type = (target_type_t*)calloc(1,sizeof(target_type_t));
+       target->type = (struct target_type*)calloc(1,sizeof(struct target_type));
 
 
-       memcpy(target->type, target_types[x], sizeof(target_type_t));
+       memcpy(target->type, target_types[x], sizeof(struct target_type));
 
        /* will be set by "-endian" */
        target->endianness = TARGET_ENDIAN_UNKNOWN;
 
        /* will be set by "-endian" */
        target->endianness = TARGET_ENDIAN_UNKNOWN;
index 3eafc18a30ec7f2db1fbf9e586acdfb3d30fd5e9..50e8c624eb4492b545fb119b01b059720a637cfe 100644 (file)
@@ -124,13 +124,10 @@ struct working_area
        struct working_area *next;
 };
 
        struct working_area *next;
 };
 
-// target_type.h contains the full definitionof struct target_type_s
-struct target_type_s;
-typedef struct target_type_s target_type_t;
-
+// target_type.h contains the full definitionof struct target_type
 typedef struct target_s
 {
 typedef struct target_s
 {
-       target_type_t *type;                            /* target type definition (name, access functions) */
+       struct target_type *type;                               /* target type definition (name, access functions) */
        const char *cmd_name;                           /* tcl Name of target */
        int target_number;                                      /* DO NOT USE!  field to be removed in 2010 */
        struct jtag_tap *tap;                                   /* where on the jtag chain is this */
        const char *cmd_name;                           /* tcl Name of target */
        int target_number;                                      /* DO NOT USE!  field to be removed in 2010 */
        struct jtag_tap *tap;                                   /* where on the jtag chain is this */
index 33288797629aa2717111258540762c1a36bc27b8..98d8665e4f530b8f5bf49d9237b63dd1647ad46f 100644 (file)
@@ -30,7 +30,7 @@
 
 struct target_s;
 
 
 struct target_s;
 
-struct target_type_s
+struct target_type
 {
        /**
         * Name of the target.  Do @b not access this field directly, use
 {
        /**
         * Name of the target.  Do @b not access this field directly, use
index fb265eaf69f1f3fc0ea04188a7a4a2a5b0509f7e..33dd3564183fc21c5ed39bd14ce1bf99cd8d6bd8 100644 (file)
@@ -3606,7 +3606,7 @@ static int xscale_register_commands(struct command_context_s *cmd_ctx)
        return ERROR_OK;
 }
 
        return ERROR_OK;
 }
 
-target_type_t xscale_target =
+struct target_type xscale_target =
 {
        .name = "xscale",
 
 {
        .name = "xscale",
 

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)