summaryrefslogtreecommitdiff
path: root/src/lib/hexdump.c
AgeCommit message (Collapse)Author
2014-05-05lib/hexdump: Use `size_t` for length parameter of `hexdump32()`Paul Menzel
In the signature of the function `hexdump32()` it does not make sense to represent a length, assumed to be positive, as a signed integer. With this change, it is no longer necessary to cast a pointer to unsigned long when passing it to `hexdump32()`. The same change for the function `hexdump()` was done in commit 3dd0e72d [1]. lib/hexdump: Take const void * and size_t as arguments [1] http://review.coreboot.org/4575 Change-Id: Id97f5daff95f94e862ee8b5be896a6629b125a13 Signed-off-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-on: http://review.coreboot.org/5646 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
2014-05-05lib/hexdump.c: Indent with tabs instead of spaces and remove empty linesPaul Menzel
The coding style requires to use tabs for indentation and not spaces. Use GNU indent 2.2.11 with the switch `-linux` to indent the file, which also removes the empty lines at the end of the file. Change-Id: I874f178e50d7558d3299026aec2771ad45f88d8e Signed-off-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-on: http://review.coreboot.org/4576 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
2014-02-11Move hexdump32() to lib/hexdump.Kyösti Mälkki
Needs printk and is not a console core function. Change-Id: Id90a363eca133af4469663c1e8b504baa70471e0 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/5155 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
2014-01-14lib/hexdump: Take const void * and size_t as argumentsAlexandru Gagniuc
Representing a memory location as an unsigned long is specific to 32-bit architectures. It also doesn't make sense to represent a length assumed to be positive as a signed integer. With this change, it is no longer necessary to cast a pointer to unsigned long when passing it to hexdump. Change-Id: I641777d940ceac6f37c363051f1e9c1b3ec3ed95 Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com> Reviewed-on: http://review.coreboot.org/4575 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
2013-12-21Add simple hexdump functionStefan Reinauer
- prints hex and ascii - detects duplicate all zero lines Change-Id: I557fed34f0f50ae256a019cf893004a0d6cbff7c Signed-off-by: Stefan Reinauer <reinauer@google.com> Reviewed-on: https://gerrit.chromium.org/gerrit/62655 Reviewed-by: David Hendricks <dhendrix@chromium.org> Tested-by: Stefan Reinauer <reinauer@chromium.org> Commit-Queue: Stefan Reinauer <reinauer@chromium.org> Reviewed-on: http://review.coreboot.org/4392 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>