summaryrefslogtreecommitdiffstats
path: root/lib/display_options.c
Commit message (Collapse)AuthorAgeFilesLines
* unify version_stringAndreas Bießmann2011-07-281-2/+1
| | | | | | | | | | | | This patch removes the architecture specific implementation of version_string where possible. Some architectures use a special place and therefore we provide U_BOOT_VERSION_STRING definition and a common weak symbol version_string. Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com> CC: Mike Frysinger <vapier@gentoo.org> CC: Peter Pan <pppeterpppan@gmail.com> Acked-by: Mike Frysinger <vapier@gentoo.org>
* display_buffer: fix misaligned bufferReinhard Meyer2010-09-131-12/+15
| | | | | | use a union to cause necessary alignment per architecture Signed-off-by: Reinhard Meyer <u-boot@emk-elektronik.de>
* print_buffer: optimize & shrinkMike Frysinger2010-08-091-14/+13
| | | | | | | | | | | | | 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>
* Avoid use of divides in print_sizeNick Thompson2010-05-171-6/+8
| | | | | | | | | | | Modification of print_size to avoid use of divides and especially long long divides. Keep the binary scale factor in terms of bit shifts instead. This should be faster, since the previous code gave the compiler no clues that the divides where always powers of two, preventing optimisation. Signed-off-by: Nick Thompson <nick.thompson@ge.com> Acked-by: Timur Tabi <timur@freescale.com>
* allow print_size to print large numbers on 32-bit systemsTimur Tabi2010-05-051-14/+19
| | | | | | | | | | Modify print_size() so that it can accept numbers larger than 4GB on 32-bit systems. Add support for display terabyte, petabyte, and exabyte sizes. Change the output to use International Electrotechnical Commission binary prefix standard. Signed-off-by: Timur Tabi <timur@freescale.com>
* fix print_size printing fractional gigabyte numbers on 32-bit platformsTimur Tabi2010-05-051-2/+2
| | | | | | | | | | In print_size(), the math that calculates the fractional remainder of a number used the same integer size as a physical address. However, the "10 *" factor of the algorithm means that a large number (e.g. 1.5GB) can overflow the integer if we're running on a 32-bit system. Therefore, we need to disassociate this function from the size of a physical address. Signed-off-by: Timur Tabi <timur@freescale.com>
* Rename lib_generic/ to lib/Peter Tyser2010-04-131-0/+145
Now that the other architecture-specific lib directories have been moved out of the top-level directory there's not much reason to have the '_generic' suffix on the common lib directory. Signed-off-by: Peter Tyser <ptyser@xes-inc.com>
OpenPOWER on IntegriCloud