[PATCH] board: raspberrypi: Fix format specifier for printing rev_scheme
Peter Robinson
pbrobinson at gmail.com
Fri Jul 12 12:41:31 CEST 2024
On Tue, 9 Jul 2024 at 13:20, Francois Berder <fberder at outlook.fr> wrote:
>
> rev_scheme is an unsigned integer and must not be printed
> as a signed integer.
>
Reviewed-by: Peter Robinson <pbrobinson at gmail.com>
> Signed-off-by: Francois Berder <fberder at outlook.fr>
> ---
> board/raspberrypi/rpi/rpi.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/board/raspberrypi/rpi/rpi.c b/board/raspberrypi/rpi/rpi.c
> index d996eb0cf6..caa4483117 100644
> --- a/board/raspberrypi/rpi/rpi.c
> +++ b/board/raspberrypi/rpi/rpi.c
> @@ -381,7 +381,7 @@ static void set_board_info(void)
>
> snprintf(s, sizeof(s), "0x%X", revision);
> env_set("board_revision", s);
> - snprintf(s, sizeof(s), "%d", rev_scheme);
> + snprintf(s, sizeof(s), "%u", rev_scheme);
> env_set("board_rev_scheme", s);
> /* Can't rename this to board_rev_type since it's an ABI for scripts */
> snprintf(s, sizeof(s), "0x%X", rev_type);
> --
> 2.34.1
>
More information about the U-Boot
mailing list