Skip to content
Commit f52352f6 authored by Matwey V. Kornilov's avatar Matwey V. Kornilov Committed by Tom Rini
Browse files

display_options: Do not use %llu in print_size



tiny-printf variant doesn't know how to handle %llu format string, but both
tiny-printf and print_size can meet in SPL when TFTP is used to obtain main
u-boot image. This is known to lead to critical boot issue at AM335x platform
when printf is catched in infinite loop.

To avoid such issues and make print_size function tiny-printf friendly, use %u
instead of %luu. Note, that the size value is guaranteed to be less than 1024
in this conditional branch, so the cast to unsigned int is safe.

Signed-off-by: default avatarMatwey V. Kornilov <matwey.kornilov@gmail.com>
Reviewed-by: default avatarSimon Glass <sjg@chromium.org>
parent c091f652
Loading
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment