summaryrefslogtreecommitdiff
path: root/src/helper/binarybuffer.h
Commit message (Collapse)AuthorAgeFilesLines
* change #include "types.h" to <helper/types.h>Zachary T Welch2009-12-031-1/+1
| | | | | | | | | | | | Changes from the flat namespace to heirarchical one. Instead of writing: #include "types.h" the following form should be used. #include <helper/types.h> The exception is from .c files in the same directory.
* binarybuffer: regression fixDavid Brownell2009-11-161-2/+4
| | | | | | | The "improve inline binarybuffer helpers" mis-handled bytes with the high bit set; treat them as unsigned, not signed. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* rename CEIL as DIV_ROUND_UPZachary T Welch2009-11-161-2/+0
| | | | | Improves the name of this macro, moves it to types.h, and adds a block of Doxygen comments to describe what it does.
* binarybuffer: add API documentationZachary T Welch2009-11-161-3/+41
| | | | | Adds Doxygen documentation for a number of the binarybuffer APIs, including "unexpected" behavior exposed during review on the list.
* improve inline binarybuffer helpersZachary T Welch2009-11-161-7/+8
| | | | Use void*, unsigned, and bool types with inline helpers.
* improve buf_set_buf helperZachary T Welch2009-11-161-2/+2
| | | | | Use void * and unsigned types for buffer and their sizes. Allows it to be used with more than uint8_t * without casts.
* improve buf_set_onesZachary T Welch2009-11-161-1/+2
| | | | Use memset instead of loop. Improve types, using void * and unsigned.
* improve buf_cpy helperZachary T Welch2009-11-161-1/+2
| | | | | Use memcpy for bulk of copy, improve final byte handling. Improve types by using void * for buffers and unsigned for size.
* improve buf_cmp and buf_cmp_mask helpersZachary T Welch2009-11-161-3/+3
| | | | | | | | Rewrite buf_cmp to use memcpy for bulk of comparison. Add static helper to perform comparison of trailing byte, which uses another static helper to perform a maksed comparison. The masked comparison helper is used by the buf_cmp_mask to simplify its loop. Improve types to use void *, unsigned, and return bool.
* improve str_to_buf and buf_to_str helpersZachary T Welch2009-11-161-3/+3
| | | | | Improve types: use void * and unsigned. Move all variables to point of first use. Move radix guessing logic to new str_radix_guess helper.
* binarybuffer: move variables to point of first useZachary T Welch2009-11-161-4/+2
| | | | Reduce some noise from subsequent patches.
* binarybuffer: fix whitespace related issuesZachary T Welch2009-11-161-20/+15
| | | | Add inter-operator whitespace. Improve existing documentation.
* remove unused buf_to_u32_handlerZachary T Welch2009-11-141-3/+0
| | | | | | Purge an unused routine from the tree and remove a layering violation. If this code is needed, it should reappear somwhere in src/jtag/, where struct scan_field gets defined.
* struct scan_field_s -> struct scan_fieldZachary T Welch2009-11-141-2/+2
| | | | | Remove obsolete suffix from struct scan_field. Somehow, these definitions did not get updated but did not cause any errors.
* src/helper: wrap and clean headers.Zachary T Welch2009-11-091-19/+23
| | | | | Remove all useless 'extern' keywords from function prototypes. Wraps long lines for readability.
* Updates to the initial scanchain validation code:dbrownell2009-09-261-1/+1
| | | | | | | | | | | - minor bug fixes - code cleanup - update comments - improve diagnostics - etc git-svn-id: svn://svn.berlios.de/openocd/trunk@2759 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* Andreas Fritiofson <andreas.fritiofson@gmail.com> UTF8 fixesoharboe2009-07-171-1/+1
| | | | git-svn-id: svn://svn.berlios.de/openocd/trunk@2549 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* Remove whitespace at end of lines, step 2.zwelch2009-06-231-3/+3
| | | | | | | - Replace '\s*$' with ''. git-svn-id: svn://svn.berlios.de/openocd/trunk@2380 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '[<>]' whitespacezwelch2009-06-231-2/+2
| | | | | | | | | | - Replace ')\([<>]\)(' with ') \1 ('. - Replace ')\([<>]\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\([<>]\)(' with '\1 \2 ('. - Replace '\(\w\)\([<>]\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2375 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '[|]' whitespacezwelch2009-06-231-1/+1
| | | | | | | | | | - Replace ')\([|]\)(' with ') \1 ('. - Replace ')\([|]\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\([|]\)(' with '\1 \2 ('. - Replace '\(\w\)\([|]\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2374 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '+' whitespacezwelch2009-06-231-2/+2
| | | | | | | | | | - Replace ')\(+\)(' with ') \1 ('. - Replace ')\(+\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\(+\)(' with '\1 \2 ('. - Replace '\(\w\)\(+\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2373 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '=' whitespacezwelch2009-06-231-2/+2
| | | | | | | | | - Replace ')\(=\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\(=\)(' with '\1 \2 ('. - Replace '\(\w\)\(=\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2372 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '==' whitespacezwelch2009-06-231-2/+2
| | | | | | | | - Replace ')\(==\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\(==\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2371 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '<<' whitespacezwelch2009-06-231-1/+1
| | | | | | | | | - Replace ')\(<<\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\(<<\)(' with '\1 \2 ('. - Replace '\(\w\)\(<<\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2370 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '>>' whitespacezwelch2009-06-231-4/+4
| | | | | | | | | - Replace ')\(>>\)\(\w\)' with ') \1 \2'. - Replace '\(\w\)\(>>\)(' with '\1 \2 ('. - Replace '\(\w\)\(>>\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2369 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - Fixes '&&' whitespacezwelch2009-06-231-2/+2
| | | | | | | | | - Replace ')\(&&\)(' with ') \1 ('. - Replace '\(\w\)\(&&\)(' with '\1 \2 ('. - Replace '\(\w\)\(&&\)\(\w\)' with '\1 \2 \3'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2366 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* Finish transforming 'u32' to 'uint32_t'.zwelch2009-06-181-7/+7
| | | | | | | | - Replace '\([^_]\)u32' with '\1uint32_t'. - Replace '^u32' with 'uint32_t'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2281 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* Transform 'u8' to 'uint8_t'zwelch2009-06-181-11/+11
| | | | | | | | - Replace '\([^_]\)u8' with '\1uint8_t'. - Replace '^u8' with 'uint8_t'. git-svn-id: svn://svn.berlios.de/openocd/trunk@2276 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* Michael Bruck <mbruck@digenius.de> use more constoharboe2009-05-091-7/+7
| | | | git-svn-id: svn://svn.berlios.de/openocd/trunk@1686 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - added myself to copyright on files i remember adding large contributions ↵ntfreak2008-09-201-1/+1
| | | | | | | | | for over the years - cleaned up headers to match rest of code - added missing svn props for previously added files git-svn-id: svn://svn.berlios.de/openocd/trunk@987 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* added yours sincerely for files where I feel that I've made non-trivial ↵oharboe2008-07-251-0/+3
| | | | | | contributions. git-svn-id: svn://svn.berlios.de/openocd/trunk@872 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* Charles Hardin ckhardin at gmail.com oharboe2008-07-111-2/+2
| | | | | | | | | This address the >32 bit problem with drscan also added a check for bypass in the execute since this will manifest itself as a memory corruption when this check helps to debug the problem alot easier git-svn-id: svn://svn.berlios.de/openocd/trunk@794 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - fixed build issues with win32ntfreak2008-07-061-1/+0
| | | | | | | - fixed build warnings for last commit - set svn props for last commit git-svn-id: svn://svn.berlios.de/openocd/trunk@760 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* This matters for embedded devices, but is probably not observably better for ↵oharboe2008-05-071-2/+41
| | | | | | PC hosted OpenOCD. git-svn-id: svn://svn.berlios.de/openocd/trunk@647 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* added some code that will be used in upcoming minidriver work.oharboe2008-02-281-0/+10
| | | | git-svn-id: svn://svn.berlios.de/openocd/trunk@369 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - added patch "remove error handler as planned"mifi2008-01-201-1/+2
| | | | | | | https://lists.berlios.de/pipermail/openocd-development/2008-January/000665.html (thanks to oyvind Harboe for the patch) git-svn-id: svn://svn.berlios.de/openocd/trunk@260 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - str9x flash support (Thanks to Spencer Oliver)drath2006-09-281-2/+2
| | | | | | | | | | | | | - str75x flash support (Thanks to Spencer Oliver) - correct reporting of T-Bit in CPSR (Thanks to John Hartman for reporting this) - core-state (ARM/Thumb) can be switched by modifying CPSR - fixed bug in gdb_server register handling - register values > 32-bit should now be supported - several minor fixes and enhancements git-svn-id: svn://svn.berlios.de/openocd/trunk@100 b42882b7-edfa-0310-969c-e2dbd0fdcd60
* - prepare OpenOCD for branching, created ./trunk/drath2006-06-021-0/+48
git-svn-id: svn://svn.berlios.de/openocd/trunk@64 b42882b7-edfa-0310-969c-e2dbd0fdcd60