]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
tools: mkfwumdata: Improve error message specificity
authorKory Maincent <kory.maincent@bootlin.com>
Mon, 23 Feb 2026 13:18:37 +0000 (14:18 +0100)
committerIlias Apalodimas <ilias.apalodimas@linaro.org>
Thu, 26 Mar 2026 06:20:00 +0000 (08:20 +0200)
Replace the generic error message with a more informative one.
This helps users quickly understand the correct command-line argument
format when the tool reports an error.

Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
Tested-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
tools/fwumdata_src/mkfwumdata.c

index fbc2067bc12d4a730fbc115944e5759a9ab5183f..5ceec7a298033429deeee28c7f555988555096e9 100644 (file)
@@ -473,7 +473,9 @@ int main(int argc, char *argv[])
 
        /* This command takes UUIDs * images and output file. */
        if (optind + images + 1 != argc) {
-               fprintf(stderr, "Error: UUID list or output file is not specified or too much.\n");
+               fprintf(stderr,
+                       "Error: Expected %ld UUID string(s) and 1 output file, got %d argument(s).\n",
+                       images, argc - optind);
                print_usage();
                return -ERANGE;
        }