summaryrefslogtreecommitdiffstats
path: root/c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-06-21 13:12:31 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-06-22 07:29:26 +0200
commitede1a4182df68b1191b8ef2031f7a1f14813b525 (patch)
treead65a287510a97a23c0d704491a4c318d545fe2b /c
parentRename and move RTEMS_PRINTF_ATTRIBUTE() (diff)
downloadrtems-ede1a4182df68b1191b8ef2031f7a1f14813b525.tar.bz2
Make rtems/print.h independent of rtems/bspIo.h
Diffstat (limited to '')
-rw-r--r--c/src/lib/libbsp/shared/src/irq-default-handler.c2
-rw-r--r--c/src/libchip/rtc/ds1375.c1
-rw-r--r--cpukit/include/rtems/bspIo.h12
-rw-r--r--cpukit/include/rtems/print.h21
-rw-r--r--cpukit/libcsupport/src/printk_plugin.c1
-rw-r--r--cpukit/libdrvmgr/drvmgr_translate_check.c2
-rw-r--r--cpukit/libfs/src/devfs/devfs_show.c2
-rw-r--r--cpukit/libfs/src/jffs2/include/linux/kernel-rtems.h2
-rw-r--r--cpukit/libmisc/mouse/mouse_parser.c1
-rw-r--r--cpukit/libmisc/mouse/serial_mouse.c1
10 files changed, 26 insertions, 19 deletions
diff --git a/c/src/lib/libbsp/shared/src/irq-default-handler.c b/c/src/lib/libbsp/shared/src/irq-default-handler.c
index f1d1e38b0a..4f4b4be673 100644
--- a/c/src/lib/libbsp/shared/src/irq-default-handler.c
+++ b/c/src/lib/libbsp/shared/src/irq-default-handler.c
@@ -14,7 +14,7 @@
#include <inttypes.h>
-#include <rtems/print.h>
+#include <rtems/bspIo.h>
#include <bsp/irq-generic.h>
diff --git a/c/src/libchip/rtc/ds1375.c b/c/src/libchip/rtc/ds1375.c
index f7e58f24a7..4a23a0044b 100644
--- a/c/src/libchip/rtc/ds1375.c
+++ b/c/src/libchip/rtc/ds1375.c
@@ -51,6 +51,7 @@
#include <unistd.h> /* write, read, close */
#include <rtems.h>
+#include <rtems/bspIo.h>
#include <rtems/rtc.h>
#include <rtems/score/sysstate.h>
#include <libchip/rtc.h>
diff --git a/cpukit/include/rtems/bspIo.h b/cpukit/include/rtems/bspIo.h
index 4b5b2a2bf7..d0d8f83dcd 100644
--- a/cpukit/include/rtems/bspIo.h
+++ b/cpukit/include/rtems/bspIo.h
@@ -122,18 +122,6 @@ extern int putk(const char *s);
*/
extern void rtems_putc(char c);
-/**
- * Type definition for function which can be plugged in to
- * certain reporting routines to redirect the output.
- *
- * Use the RTEMS Print interface to call these functions. Do not
- * directly use them.
- *
- * If the user provides their own "printf plugin", then they may
- * redirect those reports as they see fit.
- */
-typedef int (*rtems_print_plugin_t)(void *, const char *format, va_list ap);
-
/**@}*/
#ifdef __cplusplus
diff --git a/cpukit/include/rtems/print.h b/cpukit/include/rtems/print.h
index c4dacceccf..07e50d0948 100644
--- a/cpukit/include/rtems/print.h
+++ b/cpukit/include/rtems/print.h
@@ -18,11 +18,10 @@
#ifndef _RTEMS_PRINT_H
#define _RTEMS_PRINT_H
-#include <stdbool.h>
-#include <stddef.h>
-#include <stdio.h>
+#include <rtems/score/basedefs.h>
-#include <rtems/bspIo.h>
+#include <stdarg.h>
+#include <stdio.h>
#ifdef __cplusplus
extern "C" {
@@ -36,12 +35,24 @@ extern "C" {
*/
/**
+ * Type definition for function which can be plugged in to certain reporting
+ * routines to redirect the output.
+ *
+ * Use the RTEMS Print interface to call these functions. Do not directly use
+ * them.
+ *
+ * If the user provides their own printer, then they may redirect those reports
+ * as they see fit.
+ */
+typedef int (*rtems_print_printer)(void *, const char *format, va_list ap);
+
+/**
* Type definition for the printer structure used to access the kernel print
* support.
*/
typedef struct rtems_printer {
void *context;
- rtems_print_plugin_t printer;
+ rtems_print_printer printer;
} rtems_printer;
/**
diff --git a/cpukit/libcsupport/src/printk_plugin.c b/cpukit/libcsupport/src/printk_plugin.c
index 485346d2f6..38214f8018 100644
--- a/cpukit/libcsupport/src/printk_plugin.c
+++ b/cpukit/libcsupport/src/printk_plugin.c
@@ -19,6 +19,7 @@
#endif
#include <rtems/print.h>
+#include <rtems/bspIo.h>
static int printk_plugin(
void *ignored,
diff --git a/cpukit/libdrvmgr/drvmgr_translate_check.c b/cpukit/libdrvmgr/drvmgr_translate_check.c
index e5f0b7aa30..5ee0930402 100644
--- a/cpukit/libdrvmgr/drvmgr_translate_check.c
+++ b/cpukit/libdrvmgr/drvmgr_translate_check.c
@@ -9,6 +9,8 @@
#include <drvmgr/drvmgr.h>
+#include <rtems/bspIo.h>
+
/* Calls drvmgr_translate() to translate an address range and check the result,
* a printout is generated if the check fails. See paramters of
* drvmgr_translate().
diff --git a/cpukit/libfs/src/devfs/devfs_show.c b/cpukit/libfs/src/devfs/devfs_show.c
index b5984bde4c..0ea130686a 100644
--- a/cpukit/libfs/src/devfs/devfs_show.c
+++ b/cpukit/libfs/src/devfs/devfs_show.c
@@ -17,6 +17,8 @@
#include "devfs.h"
+#include <rtems/bspIo.h>
+
void devFS_Show(void)
{
rtems_filesystem_location_info_t *rootloc = &rtems_filesystem_root->location;
diff --git a/cpukit/libfs/src/jffs2/include/linux/kernel-rtems.h b/cpukit/libfs/src/jffs2/include/linux/kernel-rtems.h
index 08520342f5..0550446915 100644
--- a/cpukit/libfs/src/jffs2/include/linux/kernel-rtems.h
+++ b/cpukit/libfs/src/jffs2/include/linux/kernel-rtems.h
@@ -18,7 +18,7 @@
#define __LINUX_RTEMS_IMPL_H__
#include <rtems.h>
-#include <rtems/print.h>
+#include <rtems/bspIo.h>
static inline char *do_kmemdup(const char *s, size_t n)
{
diff --git a/cpukit/libmisc/mouse/mouse_parser.c b/cpukit/libmisc/mouse/mouse_parser.c
index 2831f64b95..573e6cf5fd 100644
--- a/cpukit/libmisc/mouse/mouse_parser.c
+++ b/cpukit/libmisc/mouse/mouse_parser.c
@@ -40,6 +40,7 @@
#include <errno.h>
#include <rtems.h>
+#include <rtems/bspIo.h>
#include <rtems/mouse_parser.h>
#include <rtems/mw_uid.h>
diff --git a/cpukit/libmisc/mouse/serial_mouse.c b/cpukit/libmisc/mouse/serial_mouse.c
index eb993b419e..874903a607 100644
--- a/cpukit/libmisc/mouse/serial_mouse.c
+++ b/cpukit/libmisc/mouse/serial_mouse.c
@@ -20,6 +20,7 @@
#include <sys/stat.h>
#include <fcntl.h>
+#include <rtems/bspIo.h>
#include <rtems/libio.h>
#include <termios.h>
#include <rtems/termiostypes.h>