diff options
author | Øyvind Harboe <oyvind.harboe@zylin.com> | 2010-12-29 22:07:21 +0100 |
---|---|---|
committer | Øyvind Harboe <oyvind.harboe@zylin.com> | 2010-12-29 22:07:39 +0100 |
commit | 4f9a9b8ebae8425eda3a71ccb782789cd3b8f6b7 (patch) | |
tree | 5143ec75e22a2f648a9375632948ce09a16ee642 /src/target | |
parent | 8f93c0a3fe29313945a63b3f2154baef70acd796 (diff) | |
download | openocd+libswd-4f9a9b8ebae8425eda3a71ccb782789cd3b8f6b7.tar.gz openocd+libswd-4f9a9b8ebae8425eda3a71ccb782789cd3b8f6b7.tar.bz2 openocd+libswd-4f9a9b8ebae8425eda3a71ccb782789cd3b8f6b7.tar.xz openocd+libswd-4f9a9b8ebae8425eda3a71ccb782789cd3b8f6b7.zip |
warnings: use more 'const' for char *
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
Diffstat (limited to 'src/target')
-rw-r--r-- | src/target/algorithm.h | 2 | ||||
-rw-r--r-- | src/target/arm9tdmi.c | 2 | ||||
-rw-r--r-- | src/target/arm_disassembler.c | 2 | ||||
-rw-r--r-- | src/target/armv7m.c | 2 | ||||
-rw-r--r-- | src/target/dsp563xx.c | 2 | ||||
-rw-r--r-- | src/target/dsp563xx.h | 2 | ||||
-rw-r--r-- | src/target/etm.h | 2 | ||||
-rw-r--r-- | src/target/register.h | 4 | ||||
-rw-r--r-- | src/target/target_type.h | 2 |
9 files changed, 10 insertions, 10 deletions
diff --git a/src/target/algorithm.h b/src/target/algorithm.h index abb8ecfc..af1fd917 100644 --- a/src/target/algorithm.h +++ b/src/target/algorithm.h @@ -37,7 +37,7 @@ struct mem_param struct reg_param { - char *reg_name; + const char *reg_name; uint32_t size; uint8_t *value; enum param_direction direction; diff --git a/src/target/arm9tdmi.c b/src/target/arm9tdmi.c index fd507031..5c2fd9d1 100644 --- a/src/target/arm9tdmi.c +++ b/src/target/arm9tdmi.c @@ -60,7 +60,7 @@ enum arm9tdmi_vector_bit }; static const struct arm9tdmi_vector { - char *name; + const char *name; uint32_t value; } arm9tdmi_vectors[] = { {"reset", ARM9TDMI_RESET_VECTOR}, diff --git a/src/target/arm_disassembler.c b/src/target/arm_disassembler.c index f02053fb..10720f45 100644 --- a/src/target/arm_disassembler.c +++ b/src/target/arm_disassembler.c @@ -2354,7 +2354,7 @@ static int evaluate_add_sp_pc_thumb(uint16_t opcode, uint8_t Rd = (opcode >> 8) & 0x7; uint8_t Rn; uint32_t SP = opcode & (1 << 11); - char *reg_name; + const char *reg_name; instruction->type = ARM_ADD; diff --git a/src/target/armv7m.c b/src/target/armv7m.c index 03c9c7ac..4fcde16f 100644 --- a/src/target/armv7m.c +++ b/src/target/armv7m.c @@ -82,7 +82,7 @@ struct reg armv7m_gdb_dummy_cpsr_reg = */ static const struct { unsigned id; - char *name; + const char *name; unsigned bits; } armv7m_regs[] = { { ARMV7M_R0, "r0", 32 }, diff --git a/src/target/dsp563xx.c b/src/target/dsp563xx.c index 9563eea9..10fd014d 100644 --- a/src/target/dsp563xx.c +++ b/src/target/dsp563xx.c @@ -173,7 +173,7 @@ static int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_ static const struct { unsigned id; - char *name; + const char *name; unsigned bits; uint32_t r_cmd; uint32_t w_cmd; diff --git a/src/target/dsp563xx.h b/src/target/dsp563xx.h index f8070fa7..475e5165 100644 --- a/src/target/dsp563xx.h +++ b/src/target/dsp563xx.h @@ -53,7 +53,7 @@ struct dsp563xx_common struct dsp563xx_core_reg { uint32_t num; - char *name; + const char *name; uint32_t size; uint32_t r_cmd; uint32_t w_cmd; diff --git a/src/target/etm.h b/src/target/etm.h index 8a482c1e..4224de67 100644 --- a/src/target/etm.h +++ b/src/target/etm.h @@ -139,7 +139,7 @@ struct etm_context; struct etm_capture_driver { - char *name; + const char *name; const struct command_registration *commands; int (*init)(struct etm_context *etm_ctx); trace_status_t (*status)(struct etm_context *etm_ctx); diff --git a/src/target/register.h b/src/target/register.h index 0cd0ddfe..4b45fd3c 100644 --- a/src/target/register.h +++ b/src/target/register.h @@ -27,7 +27,7 @@ struct target; struct reg { - char *name; + const char *name; void *value; bool dirty; bool valid; @@ -38,7 +38,7 @@ struct reg struct reg_cache { - char *name; + const char *name; struct reg_cache *next; struct reg *reg_list; unsigned num_regs; diff --git a/src/target/target_type.h b/src/target/target_type.h index 7a8ac9c4..bfa7f937 100644 --- a/src/target/target_type.h +++ b/src/target/target_type.h @@ -42,7 +42,7 @@ struct target_type * Name of this type of target. Do @b not access this * field directly, use target_type_name() instead. */ - char *name; + const char *name; /* poll current target status */ int (*poll)(struct target *target); |