summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/sparc/shared/include
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2014-06-30 09:33:36 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2014-07-09 12:07:49 +0200
commit21abc43fb54bb2424fb96666a014ebafee3e7320 (patch)
treed02d45e9a869921e8be4e6e51feade305953c837 /c/src/lib/libbsp/sparc/shared/include
parentbsps: Basic console driver for Termios devices (diff)
downloadrtems-21abc43fb54bb2424fb96666a014ebafee3e7320.tar.bz2
bsps/sparc: Add and use shared APBUART console
Move the APBUART console driver support to the shared SPARC area so that it can be reused by other BSPs. Only the console driver initialization is now BSP specific.
Diffstat (limited to 'c/src/lib/libbsp/sparc/shared/include')
-rw-r--r--c/src/lib/libbsp/sparc/shared/include/apbuart_termios.h40
1 files changed, 40 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/sparc/shared/include/apbuart_termios.h b/c/src/lib/libbsp/sparc/shared/include/apbuart_termios.h
new file mode 100644
index 0000000000..4b54252518
--- /dev/null
+++ b/c/src/lib/libbsp/sparc/shared/include/apbuart_termios.h
@@ -0,0 +1,40 @@
+/*
+ * COPYRIGHT (c) 1989-1998.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * Modified for LEON3 BSP.
+ * COPYRIGHT (c) 2004.
+ * Gaisler Research.
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.org/license/LICENSE.
+ */
+
+#ifndef APBUART_TERMIOS_H
+#define APBUART_TERMIOS_H
+
+#include <rtems/termiostypes.h>
+#include <grlib.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
+
+struct apbuart_context {
+ struct apbuart_regs *regs;
+ unsigned int freq_hz;
+ rtems_vector_number irq;
+ volatile int sending;
+ char *buf;
+};
+
+const rtems_termios_device_handler apbuart_handler_interrupt;
+
+const rtems_termios_device_handler apbuart_handler_polled;
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+#endif /* APBUART_TERMIOS_H */