summaryrefslogtreecommitdiff
path: root/src/xsvf
diff options
context:
space:
mode:
authorZachary T Welch <zw@superlucidity.net>2009-11-16 02:53:57 -0800
committerZachary T Welch <zw@superlucidity.net>2009-11-16 09:58:11 -0800
commita94748ec6da9bdc6e25a7f73bbea723b8b55fa33 (patch)
treec6aebc5e8f39d0918f9a88dd43e373ea9d28e210 /src/xsvf
parentf0ce88b3af9a6090ac986160950d66317de5087e (diff)
downloadopenocd+libswd-a94748ec6da9bdc6e25a7f73bbea723b8b55fa33.tar.gz
openocd+libswd-a94748ec6da9bdc6e25a7f73bbea723b8b55fa33.tar.bz2
openocd+libswd-a94748ec6da9bdc6e25a7f73bbea723b8b55fa33.tar.xz
openocd+libswd-a94748ec6da9bdc6e25a7f73bbea723b8b55fa33.zip
rename CEIL as DIV_ROUND_UP
Improves the name of this macro, moves it to types.h, and adds a block of Doxygen comments to describe what it does.
Diffstat (limited to 'src/xsvf')
-rw-r--r--src/xsvf/xsvf.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/xsvf/xsvf.c b/src/xsvf/xsvf.c
index 3fe2c0fd..2e78447a 100644
--- a/src/xsvf/xsvf.c
+++ b/src/xsvf/xsvf.c
@@ -479,7 +479,7 @@ COMMAND_HANDLER(handle_xsvf_command)
field.tap = tap;
field.num_bits = xsdrsize;
field.out_value = dr_out_buf;
- field.in_value = calloc(CEIL(field.num_bits, 8), 1);
+ field.in_value = calloc(DIV_ROUND_UP(field.num_bits, 8), 1);
if (tap == NULL)
jtag_add_plain_dr_scan(1, &field, jtag_set_end_state(TAP_DRPAUSE));
@@ -933,7 +933,7 @@ COMMAND_HANDLER(handle_xsvf_command)
field.tap = tap;
field.num_bits = xsdrsize;
field.out_value = dr_out_buf;
- field.in_value = calloc(CEIL(field.num_bits, 8), 1);
+ field.in_value = calloc(DIV_ROUND_UP(field.num_bits, 8), 1);
if (attempt > 0 && verbose)
LOG_USER("LSDR retry %d", attempt);