[PATCH 02/10] Make rtems_printf_plugin() static

Sebastian Huber sebastian.huber at embedded-brains.de
Tue Jun 21 13:57:47 UTC 2016


---
 cpukit/include/rtems/bspIo.h           | 13 -------------
 cpukit/libcsupport/src/printf_plugin.c | 12 ++++++------
 2 files changed, 6 insertions(+), 19 deletions(-)

diff --git a/cpukit/include/rtems/bspIo.h b/cpukit/include/rtems/bspIo.h
index 958103a..fad4e9d 100644
--- a/cpukit/include/rtems/bspIo.h
+++ b/cpukit/include/rtems/bspIo.h
@@ -142,19 +142,6 @@ extern void rtems_putc(char c);
 typedef int (*rtems_print_plugin_t)(void *, const char *format, va_list ap);
 
 /**
- * @brief Reporting Methods printf() Plugin
- *
- * This is a standard plug-in to support using printf() for output
- * instead of printk().
- *
- * @param[in] context Unused.
- * @param[in] fmt is a printf()-style format string
- *
- * @return The number of characters printed.
- */
-extern int rtems_printf_plugin(void *context, const char *fmt, va_list ap);
-
-/**
  * @brief Reporting Methods fprintf() Plugin
  *
  * This is a standard plug-in to support using fprintf() for output
diff --git a/cpukit/libcsupport/src/printf_plugin.c b/cpukit/libcsupport/src/printf_plugin.c
index 097e412..23ac9f6 100644
--- a/cpukit/libcsupport/src/printf_plugin.c
+++ b/cpukit/libcsupport/src/printf_plugin.c
@@ -27,14 +27,14 @@
 
 #include <stdio.h>
 
-void rtems_print_printer_printf(rtems_printer *printer)
+static int rtems_printf_plugin(void *context, const char *format, va_list ap)
 {
-  printer->context = NULL;
-  printer->printer = rtems_printf_plugin;
+  (void) context;
+  return vprintf(format, ap);
 }
 
-int rtems_printf_plugin(void *context, const char *format, va_list ap)
+void rtems_print_printer_printf(rtems_printer *printer)
 {
-  (void) context;
-  return vprintf(format, ap);
+  printer->context = NULL;
+  printer->printer = rtems_printf_plugin;
 }
-- 
1.8.4.5



More information about the devel mailing list