summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/shared/src/irq-shell.c
blob: 341f30364a8316b7962fbba687b81a33ffc87037 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/**
 * @file
 *
 * @ingroup bsp_interrupt
 *
 * @brief Source file for generic BSP interrupt shell code.
 */

/*
 * Copyright (c) 2008
 * Embedded Brains GmbH
 * Obere Lagerstr. 30
 * D-82178 Puchheim
 * Germany
 * rtems@embedded-brains.de
 *
 *  The license and distribution terms for this file may be
 *  found in the file LICENSE in this distribution or at
 *  http://www.rtems.com/license/LICENSE.
 */

#include <stdio.h>

#include <rtems/shell.h>

#include <bsp/irq-info.h>

static int bsp_interrupt_shell_main( int argc, char **argv)
{
  bsp_interrupt_report_with_plugin( stdout, (rtems_printk_plugin_t) fprintf);

  return 0;
}

/**
 * @brief Shell command entry for interrupt information.
 */
struct rtems_shell_cmd_tt bsp_interrupt_shell_command = {
  .name     = "irq",
  .usage   = "Prints interrupt information",
  .topic   = "rtems",
  .command = bsp_interrupt_shell_main,
  .alias   = NULL,
  .next    = NULL
};