summaryrefslogtreecommitdiff
path: root/src/jtag/core.c
diff options
context:
space:
mode:
authorZachary T Welch <zw@superlucidity.net>2009-11-16 03:29:30 -0800
committerZachary T Welch <zw@superlucidity.net>2009-11-16 09:58:11 -0800
commitdc1685ca25567fe75c8d50c825fb0303fbb66fac (patch)
treee51e63fe1e40d3c60673f57784f88c43277f5eba /src/jtag/core.c
parent10cce4a5fe85bfd680bc338c900b0033d7174b6a (diff)
downloadopenocd_libswd-dc1685ca25567fe75c8d50c825fb0303fbb66fac.tar.gz
openocd_libswd-dc1685ca25567fe75c8d50c825fb0303fbb66fac.tar.bz2
openocd_libswd-dc1685ca25567fe75c8d50c825fb0303fbb66fac.tar.xz
openocd_libswd-dc1685ca25567fe75c8d50c825fb0303fbb66fac.zip
move ARRAY_SIZE macro to types.h
The ARRAY_SIZE macro was defined in several target files, so move it to types.h. This patch also removes two other identical macros: DIM (from jtag.h) and asizeof (from arm11.h).
Diffstat (limited to 'src/jtag/core.c')
-rw-r--r--src/jtag/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/jtag/core.c b/src/jtag/core.c
index c8a76e88..ea723ebe 100644
--- a/src/jtag/core.c
+++ b/src/jtag/core.c
@@ -586,7 +586,7 @@ int jtag_add_statemove(tap_state_t goal_state)
unsigned tms_bits = tap_get_tms_path(cur_state, goal_state);
unsigned tms_count = tap_get_tms_path_len(cur_state, goal_state);
tap_state_t moves[8];
- assert(tms_count < DIM(moves));
+ assert(tms_count < ARRAY_SIZE(moves));
for (unsigned i = 0; i < tms_count; i++, tms_bits >>= 1)
{