From: Simon Glass Date: Wed, 13 Jan 2016 16:25:18 -0700 Subject: [U-Boot] [PATCH 28/50] gpio: Allow 's' as an abbreviation for 'status' In-Reply-To: <1452727540-3249-1-git-send-email-sjg@chromium.org> References: <1452727540-3249-1-git-send-email-sjg@chromium.org> Message-ID: <1452727540-3249-29-git-send-email-sjg@chromium.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de The 'gpio' command allows abbreviations for most subcommands. Allow them for 'status' also. Signed-off-by: Simon Glass --- common/cmd_gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/cmd_gpio.c b/common/cmd_gpio.c index 65d6df4..bb0f63a 100644 --- a/common/cmd_gpio.c +++ b/common/cmd_gpio.c @@ -141,7 +141,7 @@ static int do_gpio(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #endif if (argc > 0) str_gpio = *argv; - if (!strcmp(str_cmd, "status")) { + if (!strncmp(str_cmd, "status", 1)) { /* Support deprecated gpio_status() */ #ifdef gpio_status gpio_status(); -- 2.6.0.rc2.230.g3dd15c0