From 2e192b245ed36a63bab0ef576999a95e23f60ecd Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Sun, 17 Jan 2016 20:53:52 -0700 Subject: Remove the cmd_ prefix from command files Now that they are in their own directory, we can remove this prefix. This makes it easier to find a file since the prefix does not get in the way. Signed-off-by: Simon Glass Reviewed-by: Bin Meng Reviewed-by: Heiko Schocher Acked-by: Stefan Roese Acked-by: Przemyslaw Marczak --- cmd/irq.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 cmd/irq.c (limited to 'cmd/irq.c') diff --git a/cmd/irq.c b/cmd/irq.c new file mode 100644 index 0000000000..02da450f67 --- /dev/null +++ b/cmd/irq.c @@ -0,0 +1,40 @@ +/* + * Copyright 2008 Freescale Semiconductor, Inc. + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +#include +#include +#include + +static int do_interrupts(cmd_tbl_t *cmdtp, int flag, int argc, + char * const argv[]) +{ + + if (argc != 2) + return CMD_RET_USAGE; + + /* on */ + if (strncmp(argv[1], "on", 2) == 0) + enable_interrupts(); + else + disable_interrupts(); + + return 0; +} + +U_BOOT_CMD( + interrupts, 5, 0, do_interrupts, + "enable or disable interrupts", + "[on, off]" +); + +/* Implemented in $(CPU)/interrupts.c */ +int do_irqinfo (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); + +U_BOOT_CMD( + irqinfo, 1, 1, do_irqinfo, + "print information about IRQs", + "" +); -- cgit v1.2.3