]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
tools: kwboot: Always print kwboot version
authorPali Rohár <pali@kernel.org>
Fri, 5 Nov 2021 22:30:42 +0000 (23:30 +0100)
committerStefan Roese <sr@denx.de>
Wed, 10 Nov 2021 11:08:06 +0000 (12:08 +0100)
It is useful to see kwboot version in the boot log output for debugging
purposes.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
tools/kwboot.c

index 4e4d544efd3fb6acf6087fa97f0a4ad11ea113ea..d22e6ea96a5cf9b2749dd4a83c337df937c9aabf 100644 (file)
@@ -1640,7 +1640,6 @@ err:
 static void
 kwboot_usage(FILE *stream, char *progname)
 {
-       fprintf(stream, "kwboot version %s\n", PLAIN_VERSION);
        fprintf(stream,
                "Usage: %s [OPTIONS] [-b <image> | -D <image> ] [-B <baud> ] <TTY>\n",
                progname);
@@ -1685,6 +1684,8 @@ main(int argc, char **argv)
        after_img_rsv = KWBOOT_XM_BLKSZ;
        baudrate = 115200;
 
+       printf("kwboot version %s\n", PLAIN_VERSION);
+
        kwboot_verbose = isatty(STDOUT_FILENO);
 
        do {