X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=tools%2Fmxsboot.c;h=6c05aa479d4360c0c14cd0f989c250ecf119126d;hb=a1f41f1a55230dcd2e195f193809901fc4a082cf;hp=176753d2ce07078dc1fe053b70539ab9c45822bd;hpb=9dfa8da709a1589d177d99c597d9b18d8c9a145d;p=u-boot diff --git a/tools/mxsboot.c b/tools/mxsboot.c index 176753d2ce..6c05aa479d 100644 --- a/tools/mxsboot.c +++ b/tools/mxsboot.c @@ -453,7 +453,7 @@ static int mx28_nand_write_firmware(struct mx28_nand_fcb *fcb, int infd, void usage(void) { printf( - "Usage: mx28image [ops] \n" + "Usage: mxsboot [ops] \n" "Augment BootStream file with a proper header for i.MX28 boot\n" "\n" " type of image:\n" @@ -606,6 +606,9 @@ int parse_ops(int argc, char **argv) }; int type; + if (argc < 4) + return -1; + for (i = 1; i < argc; i++) { if (!strncmp(argv[i], "-w", 2)) type = PARAM_WRITE;