summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/shared/src/irq-shell.c
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2008-12-19 15:00:09 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2008-12-19 15:00:09 +0000
commit51a6fd555d2f20506b4b235b0046d0b4b57708f4 (patch)
tree15f27917466370362451e3d869860949156880e6 /c/src/lib/libbsp/shared/src/irq-shell.c
parent2008-12-19 Sebastian Huber <sebastian.huber@embedded-brains.de> (diff)
downloadrtems-51a6fd555d2f20506b4b235b0046d0b4b57708f4.tar.bz2
2008-12-19 Sebastian Huber <sebastian.huber@embedded-brains.de>
* include/irq-info.h, src/irq-info.c, src/irq-shell.c: New files. * include/irq-generic.h, src/irq-generic.c: Improved interrupt handler dispatch function.
Diffstat (limited to '')
-rw-r--r--c/src/lib/libbsp/shared/src/irq-shell.c45
1 files changed, 45 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/shared/src/irq-shell.c b/c/src/lib/libbsp/shared/src/irq-shell.c
new file mode 100644
index 0000000000..341f30364a
--- /dev/null
+++ b/c/src/lib/libbsp/shared/src/irq-shell.c
@@ -0,0 +1,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
+};