[PATCH 32/42] lpc176x/console/console-config.c: Conditionalize code to avoid unused warnings

Joel Sherrill joel.sherrill at oarcorp.com
Mon Mar 23 14:39:30 UTC 2015


---
 c/src/lib/libbsp/arm/lpc176x/console/console-config.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/c/src/lib/libbsp/arm/lpc176x/console/console-config.c b/c/src/lib/libbsp/arm/lpc176x/console/console-config.c
index a4fe30f..c80932d 100644
--- a/c/src/lib/libbsp/arm/lpc176x/console/console-config.c
+++ b/c/src/lib/libbsp/arm/lpc176x/console/console-config.c
@@ -74,6 +74,7 @@ static bool lpc176x_uart1_probe(rtems_termios_device_context *ctx)
   return true;
 }
 
+#ifdef LPC176X_CONFIG_UART_2
 static bool lpc176x_uart2_probe(rtems_termios_device_context *ctx)
 {
   (void)ctx;
@@ -85,7 +86,9 @@ static bool lpc176x_uart2_probe(rtems_termios_device_context *ctx)
 
   return true;
 }
+#endif
 
+#ifdef LPC176X_CONFIG_UART_3
 static bool lpc176x_uart3_probe(rtems_termios_device_context *ctx)
 {
   (void)ctx;
@@ -97,6 +100,7 @@ static bool lpc176x_uart3_probe(rtems_termios_device_context *ctx)
 
   return true;
 }
+#endif
 
 #ifdef LPC176X_CONFIG_CONSOLE
 static ns16550_context lpc176x_uart_context_0 = {
-- 
1.9.3




More information about the devel mailing list