From 65d342541e78ab9a22bf480cc4fe2f659f94bad4 Mon Sep 17 00:00:00 2001 From: Serge Ziryukin Date: Sun, 25 Apr 2010 21:32:36 +0300 Subject: [PATCH] cmd_usb.c: show cmd usage if no args given Signed-off-by: Serge Ziryukin --- common/cmd_usb.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/common/cmd_usb.c b/common/cmd_usb.c index ee3755c121..fcb5f763c0 100644 --- a/common/cmd_usb.c +++ b/common/cmd_usb.c @@ -516,6 +516,11 @@ int do_usb(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) block_dev_desc_t *stor_dev; #endif + if (argc < 2) { + cmd_usage(cmdtp); + return 1; + } + if ((strncmp(argv[1], "reset", 5) == 0) || (strncmp(argv[1], "start", 5) == 0)) { usb_stop(); -- 2.25.1