1
2
3
4
5
6#include <common.h>
7#include <config.h>
8#include <command.h>
9
10static int do_interrupts(cmd_tbl_t *cmdtp, int flag, int argc,
11 char * const argv[])
12{
13
14 if (argc != 2)
15 return CMD_RET_USAGE;
16
17
18 if (strncmp(argv[1], "on", 2) == 0)
19 enable_interrupts();
20 else
21 disable_interrupts();
22
23 return 0;
24}
25
26U_BOOT_CMD(
27 interrupts, 5, 0, do_interrupts,
28 "enable or disable interrupts",
29 "[on, off]"
30);
31
32
33int do_irqinfo (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]);
34
35U_BOOT_CMD(
36 irqinfo, 1, 1, do_irqinfo,
37 "print information about IRQs",
38 ""
39);
40