From 59ac0e4d0352fad72b80018438e350ba405294b5 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 8 Oct 2014 11:34:22 -0600 Subject: Update everything under apps/ to use the corrected syslog interfaces --- apps/system/cdcacm/cdcacm.h | 20 -------------------- apps/system/cdcacm/cdcacm_main.c | 14 +++++++------- 2 files changed, 7 insertions(+), 27 deletions(-) (limited to 'apps/system/cdcacm') diff --git a/apps/system/cdcacm/cdcacm.h b/apps/system/cdcacm/cdcacm.h index bc9cf2f9e..d8a351239 100644 --- a/apps/system/cdcacm/cdcacm.h +++ b/apps/system/cdcacm/cdcacm.h @@ -108,26 +108,6 @@ #define TRACE_BITSET (TRACE_INIT_BITS|TRACE_ERROR_BITS|TRACE_CLASS_BITS|\ TRACE_TRANSFER_BITS|TRACE_CONTROLLER_BITS|TRACE_INTERRUPT_BITS) -/* Debug ********************************************************************/ - -#ifdef CONFIG_CPP_HAVE_VARARGS -# ifdef CONFIG_DEBUG -# define message(...) lowsyslog(__VA_ARGS__) -# define msgflush() -# else -# define message(...) printf(__VA_ARGS__) -# define msgflush() fflush(stdout) -# endif -#else -# ifdef CONFIG_DEBUG -# define message lowsyslog -# define msgflush() -# else -# define message printf -# define msgflush() fflush(stdout) -# endif -#endif - /**************************************************************************** * Public Types ****************************************************************************/ diff --git a/apps/system/cdcacm/cdcacm_main.c b/apps/system/cdcacm/cdcacm_main.c index e8ebebb2d..a9f8b504c 100644 --- a/apps/system/cdcacm/cdcacm_main.c +++ b/apps/system/cdcacm/cdcacm_main.c @@ -50,7 +50,7 @@ #include "cdcacm.h" /**************************************************************************** - * Definitions + * Pre-processor Definitions ****************************************************************************/ /**************************************************************************** @@ -93,7 +93,7 @@ int sercon_main(int argc, char *argv[]) if (g_cdcacm.handle) { - message("sercon:: ERROR: Already connected\n"); + printf("sercon:: ERROR: Already connected\n"); return EXIT_FAILURE; } @@ -105,15 +105,15 @@ int sercon_main(int argc, char *argv[]) /* Initialize the USB CDC/ACM serial driver */ - message("sercon: Registering CDC/ACM serial driver\n"); + printf("sercon: Registering CDC/ACM serial driver\n"); ret = cdcacm_initialize(CONFIG_SYSTEM_CDCACM_DEVMINOR, &g_cdcacm.handle); if (ret < 0) { - message("sercon: ERROR: Failed to create the CDC/ACM serial device: %d\n", -ret); + printf("sercon: ERROR: Failed to create the CDC/ACM serial device: %d\n", -ret); return EXIT_FAILURE; } - message("sercon: Successfully registered the CDC/ACM serial driver\n"); + printf("sercon: Successfully registered the CDC/ACM serial driver\n"); return EXIT_SUCCESS; } @@ -136,7 +136,7 @@ int serdis_main(int argc, char *argv[]) if (!g_cdcacm.handle) { - message("serdis: ERROR: Not connected\n"); + printf("serdis: ERROR: Not connected\n"); return EXIT_FAILURE; } @@ -150,6 +150,6 @@ int serdis_main(int argc, char *argv[]) cdcacm_uninitialize(g_cdcacm.handle); g_cdcacm.handle = NULL; - message("serdis: Disconnected\n"); + printf("serdis: Disconnected\n"); return EXIT_SUCCESS; } -- cgit v1.2.3