public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Fix format specifier for net_boot_file_size
@ 2023-08-14  4:53 Siddharth Vadapalli
  2023-08-14  4:53 ` [PATCH v2 1/2] net: Fix the displayed value of bytes transferred Siddharth Vadapalli
  2023-08-14  4:53 ` [PATCH v2 2/2] doc: printf() codes: Fix format specifier for unsigned int Siddharth Vadapalli
  0 siblings, 2 replies; 6+ messages in thread
From: Siddharth Vadapalli @ 2023-08-14  4:53 UTC (permalink / raw)
  To: trini, joe.hershberger, rfried.dev, sjg
  Cc: u-boot, r-gunasekaran, s-vadapalli

Hello,

This series fixes the format specifier for printing the decimal value of
the variable "net_boot_file_size", changing it from "%d" to "%u". With
the format specifier being "%d", for large file sizes, the value
displayed is negative. Using "%u" fixes this.

Additionally, as reported by Tom Rini <trini@konsulko.com> in the mail
thread corresponding to the v1 patch of this series, the documentation
for the printf format specifiers needs to be fixed for the "unsigned
int" variable. Thus, update the documentation as well.

Regards,
Siddharth.

---
v1:
https://patchwork.ozlabs.org/project/uboot/patch/20230810091523.3168975-1-s-vadapalli@ti.com/

Changes since v1:
- Use "%u" instead of "%lu" to display the decimal value of the u32
  variable "net_boot_file_size", as suggested by Tom Rini.
- Add a new patch to update the documentation for printf format
  specifiers, changing the format specifier from "%d" to "%u" for the
  "unsigned int" variable, as reported by Tom Rini.

Siddharth Vadapalli (2):
  net: Fix the displayed value of bytes transferred
  doc: printf() codes: Fix format specifier for unsigned int

 doc/develop/printf.rst | 2 +-
 net/net.c              | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

-- 
2.34.1


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

end of thread, other threads:[~2023-08-23 14:44 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-14  4:53 [PATCH v2 0/2] Fix format specifier for net_boot_file_size Siddharth Vadapalli
2023-08-14  4:53 ` [PATCH v2 1/2] net: Fix the displayed value of bytes transferred Siddharth Vadapalli
2023-08-14 15:03   ` Tom Rini
2023-08-23 14:42   ` Tom Rini
2023-08-14  4:53 ` [PATCH v2 2/2] doc: printf() codes: Fix format specifier for unsigned int Siddharth Vadapalli
2023-08-14 15:04   ` Tom Rini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox