diff options
author | Mike Frysinger <vapier@gentoo.org> | 2010-07-23 06:17:30 -0400 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2010-08-09 00:28:38 +0200 |
commit | 64419e47518bbba059c80b77558f93ad4804145c (patch) | |
tree | ba402e033d5191592d045c3eaee6d1a3bf7da0ed /lib/crc16.c | |
parent | 8faba4894c6e2bafbfab17260f3db17867cd50d2 (diff) | |
download | u-boot-imx-64419e47518bbba059c80b77558f93ad4804145c.zip u-boot-imx-64419e47518bbba059c80b77558f93ad4804145c.tar.gz u-boot-imx-64419e47518bbba059c80b77558f93ad4804145c.tar.bz2 |
print_buffer: optimize & shrink
Applying a little creative format string allows us to shrink the initial
data read & display loop by only calling printf once. Re-using the local
data buffer to generate the string we want to display then allows us to
output everything with just one printf call instead of multiple calls to
the putc function.
The local stack buffer needs increasing by 1 byte, but the resulting code
shrink and speed up is worth it I think.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'lib/crc16.c')
0 files changed, 0 insertions, 0 deletions