All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/12] display_options: Start to unify print_buffer() and hexdump
@ 2021-05-08 12:59 Simon Glass
  2021-05-08 12:59 ` [PATCH v2 01/12] console: Report an error when output buffer is exhausted Simon Glass
                   ` (12 more replies)
  0 siblings, 13 replies; 14+ messages in thread
From: Simon Glass @ 2021-05-08 12:59 UTC (permalink / raw)
  To: u-boot

At present we have two ways of showing a hex dump. Once has been in U-Boot
since the dawn of time and the other was recently added from Linux.

They both have their own unique features.

This series makes a few changes to bring them closer together. It also
adds support for logging a buffer, which is useful since it can put it
through the same log drivers as other logging output.

Also it adds tests, so we can check the behaviour.

The code-size impact of the main part of this series is 160 bytes on
Thumb2, which seems acceptable. However the final patch adds another 600
bytes or so, which is not.

Changes in v2:
- Drop unwanted #if at top of file
- Fix sandbox build error

Simon Glass (12):
  console: Report an error when output buffer is exhausted
  test: Detect when expect_str is too small
  test: Convert print tests to use ut framework
  test: Add a test for print_buffer()
  display_options: Drop two spaces before the ASCII column
  hexdump: Move API to header file
  hexdump: Add support for sandbox
  hexdump: Support any rowsize
  hexdump: Allow ctrl-c to interrupt output
  display_options: Split print_buffer() into two functions
  log: Add support for logging a buffer
  RFC: display_options: Use print_hex_dump() for print_buffer()

 common/console.c                  |  18 +-
 common/log.c                      |  30 ++++
 include/asm-generic/global_data.h |  16 +-
 include/console.h                 |   3 +-
 include/display_options.h         |  25 +++
 include/hexdump.h                 |  81 ++++++++-
 include/log.h                     |  35 ++++
 include/test/suites.h             |   1 +
 include/test/test.h               |   4 +-
 lib/display_options.c             | 124 ++++++++-----
 lib/hexdump.c                     | 104 +++--------
 test/cmd/mem_search.c             |  26 +--
 test/cmd_ut.c                     |   2 +
 test/dm/rtc.c                     |   9 +-
 test/log/log_test.c               |  27 +++
 test/print_ut.c                   | 284 ++++++++++++++++++++++++------
 test/ut.c                         |  55 +++++-
 17 files changed, 629 insertions(+), 215 deletions(-)

-- 
2.31.1.607.g51e8a6a459-goog

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2021-06-08 21:43 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-08 12:59 [PATCH v2 00/12] display_options: Start to unify print_buffer() and hexdump Simon Glass
2021-05-08 12:59 ` [PATCH v2 01/12] console: Report an error when output buffer is exhausted Simon Glass
2021-05-08 12:59 ` [PATCH v2 02/12] test: Detect when expect_str is too small Simon Glass
2021-05-08 12:59 ` [PATCH v2 03/12] test: Convert print tests to use ut framework Simon Glass
2021-05-08 12:59 ` [PATCH v2 04/12] test: Add a test for print_buffer() Simon Glass
2021-05-08 13:00 ` [PATCH v2 05/12] display_options: Drop two spaces before the ASCII column Simon Glass
2021-05-08 13:00 ` [PATCH v2 06/12] hexdump: Move API to header file Simon Glass
2021-05-08 13:00 ` [PATCH v2 07/12] hexdump: Add support for sandbox Simon Glass
2021-05-08 13:00 ` [PATCH v2 08/12] hexdump: Support any rowsize Simon Glass
2021-05-08 13:00 ` [PATCH v2 09/12] hexdump: Allow ctrl-c to interrupt output Simon Glass
2021-05-08 13:00 ` [PATCH v2 10/12] display_options: Split print_buffer() into two functions Simon Glass
2021-05-08 13:00 ` [PATCH v2 11/12] log: Add support for logging a buffer Simon Glass
2021-05-08 13:00 ` [PATCH v2 12/12] RFC: display_options: Use print_hex_dump() for print_buffer() Simon Glass
2021-06-08 21:43 ` [PATCH v2 00/12] display_options: Start to unify print_buffer() and hexdump Tom Rini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.