summaryrefslogtreecommitdiff
path: root/src/target/target.c
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/target/target.c
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/target/target.c')
-rw-r--r--src/target/target.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/target/target.c b/src/target/target.c
index f5a092a7..c24085f1 100644
--- a/src/target/target.c
+++ b/src/target/target.c
@@ -1967,7 +1967,7 @@ COMMAND_HANDLER(handle_reg_command)
/* set register value */
if (argc == 2)
{
- uint8_t *buf = malloc(CEIL(reg->size, 8));
+ uint8_t *buf = malloc(DIV_ROUND_UP(reg->size, 8));
str_to_buf(args[1], strlen(args[1]), buf, reg->size, 0);
struct reg_arch_type *arch_type = register_get_arch_type(reg->arch_type);