Change all variadic macros to C99 style

This commit is contained in:
Gregory Nutt
2014-05-22 09:01:51 -06:00
parent 43f9282517
commit f3df5f2bb5
18 changed files with 34 additions and 33 deletions
@@ -130,7 +130,7 @@ index c78362f..207f9b9 100644
+#if 0 +#if 0
#ifdef CONFIG_CPP_HAVE_VARARGS #ifdef CONFIG_CPP_HAVE_VARARGS
# define nsh_output(v, fmt...) (v)->output(v, ##fmt) # define nsh_output(v, ...) (v)->output(v, ##__VA_ARGS__)
#else #else
# define nsh_output vtbl->output # define nsh_output vtbl->output
#endif #endif
+2 -1
View File
@@ -65,8 +65,9 @@
# define LCD_YRES 67 # define LCD_YRES 67
/* Debug ******************************************************************************/ /* Debug ******************************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) vdbg(format, ##arg) # define lcddbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
#endif #endif
+1 -1
View File
@@ -94,7 +94,7 @@
/* Debug ******************************************************************************/ /* Debug ******************************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) vdbg(format, ##arg) # define lcddbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
#endif #endif
+1 -1
View File
@@ -61,7 +61,7 @@
/* Debug ******************************************************************************/ /* Debug ******************************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) vdbg(format, ##arg) # define lcddbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
#endif #endif
+1 -1
View File
@@ -71,7 +71,7 @@
#endif #endif
#ifdef CONFIG_LCD_RITDEBUG #ifdef CONFIG_LCD_RITDEBUG
# define ritdbg(format, arg...) vdbg(format, ##arg) # define ritdbg(format, ...) vdbg(format, ##__VA_ARGS__)
# define oleddc_dumpgpio(m) tiva_dumpgpio(OLEDDC_GPIO, m) # define oleddc_dumpgpio(m) tiva_dumpgpio(OLEDDC_GPIO, m)
# define oledcs_dumpgpio(m) tiva_dumpgpio(OLEDCS_GPIO, m) # define oledcs_dumpgpio(m) tiva_dumpgpio(OLEDCS_GPIO, m)
#else #else
+1 -1
View File
@@ -71,7 +71,7 @@
#endif #endif
#ifdef CONFIG_LCD_RITDEBUG #ifdef CONFIG_LCD_RITDEBUG
# define ritdbg(format, arg...) vdbg(format, ##arg) # define ritdbg(format, ...) vdbg(format, ##__VA_ARGS__)
# define oleddc_dumpgpio(m) tiva_dumpgpio(OLEDDC_GPIO, m) # define oleddc_dumpgpio(m) tiva_dumpgpio(OLEDDC_GPIO, m)
# define oledcs_dumpgpio(m) tiva_dumpgpio(OLEDCS_GPIO, m) # define oledcs_dumpgpio(m) tiva_dumpgpio(OLEDCS_GPIO, m)
#else #else
+1 -1
View File
@@ -85,7 +85,7 @@
#endif #endif
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define ugdbg(format, arg...) vdbg(format, ##arg) # define ugdbg(format, ...) vdbg(format, ##__VA_ARGS__)
# define oleddc_dumpgpio(m) lpc17_dumpgpio(LPCXPRESSO_OLED_POWER, m) # define oleddc_dumpgpio(m) lpc17_dumpgpio(LPCXPRESSO_OLED_POWER, m)
# define oledcs_dumpgpio(m) lpc17_dumpgpio(LPCXPRESSO_OLED_CS, m) # define oledcs_dumpgpio(m) lpc17_dumpgpio(LPCXPRESSO_OLED_CS, m)
#else #else
+1 -1
View File
@@ -83,7 +83,7 @@
#endif #endif
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) vdbg(format, ##arg) # define lcddbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
#endif #endif
+1 -1
View File
@@ -86,7 +86,7 @@
#endif #endif
#ifdef CONFIG_LCD_NOKIADBG #ifdef CONFIG_LCD_NOKIADBG
# define lcddbg(format, arg...) vdbg(format, ##arg) # define lcddbg(format, ...) vdbg(format, ##__VA_ARGS__)
# define lcd_dumpgpio(m) lpc17_dumpgpio(LPC1766STK_LCD_RST, m) # define lcd_dumpgpio(m) lpc17_dumpgpio(LPC1766STK_LCD_RST, m)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
+3 -3
View File
@@ -159,14 +159,14 @@
/* Debug ******************************************************************************/ /* Debug ******************************************************************************/
#ifdef CONFIG_LCD_REGDEBUG #ifdef CONFIG_LCD_REGDEBUG
# define regdbg(format, arg...) vdbg(format, ##arg) # define regdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define regdbg(x...) # define regdbg(x...)
#endif #endif
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) dbg(format, ##arg) # define lcddbg(format, ...) dbg(format, ##__VA_ARGS__)
# define lcdvdbg(format, arg...) vdbg(format, ##arg) # define lcdvdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
# define lcdvdbg(x...) # define lcdvdbg(x...)
@@ -114,8 +114,8 @@
/* Debug ********************************************************************/ /* Debug ********************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) dbg(format, ##arg) # define lcddbg(format, ...) dbg(format, ##__VA_ARGS__)
# define lcdvdbg(format, arg...) vdbg(format, ##arg) # define lcdvdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
# define lcdvdbg(x...) # define lcdvdbg(x...)
@@ -144,8 +144,8 @@
/* Debug ********************************************************************/ /* Debug ********************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) dbg(format, ##arg) # define lcddbg(format, ...) dbg(format, ##__VA_ARGS__)
# define lcdvdbg(format, arg...) vdbg(format, ##arg) # define lcdvdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
# define lcdvdbg(x...) # define lcdvdbg(x...)
+1 -1
View File
@@ -312,7 +312,7 @@
/* Debug ******************************************************************************/ /* Debug ******************************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) vdbg(format, ##arg) # define lcddbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
#endif #endif
@@ -93,8 +93,8 @@
/* Debug ********************************************************************/ /* Debug ********************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) dbg(format, ##arg) # define lcddbg(format, ...) dbg(format, ##__VA_ARGS__)
# define lcdvdbg(format, arg...) vdbg(format, ##arg) # define lcdvdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
# define lcdvdbg(x...) # define lcdvdbg(x...)
@@ -93,8 +93,8 @@
/* Debug ********************************************************************/ /* Debug ********************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) dbg(format, ##arg) # define lcddbg(format, ...) dbg(format, ##__VA_ARGS__)
# define lcdvdbg(format, arg...) vdbg(format, ##arg) # define lcdvdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
# define lcdvdbg(x...) # define lcdvdbg(x...)
+2 -2
View File
@@ -62,8 +62,8 @@
#define DEFAULT_BAUD 9600 #define DEFAULT_BAUD 9600
#define dbg(format, arg...) if (debug > 0) printconsole(format, ##arg) #define dbg(format, ...) if (debug > 0) printconsole(format, ##__VA_ARGS__)
#define vdbg(format, arg...) if (debug > 1) printconsole(format, ##arg) #define vdbg(format, ...) if (debug > 1) printconsole(format, ##__VA_ARGS__)
/**************************************************************************** /****************************************************************************
* Private Types * Private Types
@@ -130,7 +130,7 @@ index c78362f..207f9b9 100644
+#if 0 +#if 0
#ifdef CONFIG_CPP_HAVE_VARARGS #ifdef CONFIG_CPP_HAVE_VARARGS
# define nsh_output(v, fmt...) (v)->output(v, ##fmt) # define nsh_output(v, ...) (v)->output(v, ##__VA_ARGS__)
#else #else
# define nsh_output vtbl->output # define nsh_output vtbl->output
#endif #endif
+2 -2
View File
@@ -99,8 +99,8 @@
/* Debug ********************************************************************/ /* Debug ********************************************************************/
#ifdef CONFIG_DEBUG_LCD #ifdef CONFIG_DEBUG_LCD
# define lcddbg(format, arg...) dbg(format, ##arg) # define lcddbg(format, ...) dbg(format, ##__VA_ARGS__)
# define lcdvdbg(format, arg...) vdbg(format, ##arg) # define lcdvdbg(format, ...) vdbg(format, ##__VA_ARGS__)
#else #else
# define lcddbg(x...) # define lcddbg(x...)
# define lcdvdbg(x...) # define lcdvdbg(x...)