aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/m32r_sio.c
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2016-01-12 04:59:08 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-02-07 01:16:58 -0500
commitad245aa2750212a8daae44d6dc2f3d34b94d74c6 (patch)
treebe2a4c35d2b95a4be00a69d9d85ef34583b31a78 /drivers/tty/serial/m32r_sio.c
parentc8e7d143d519724b3bf5b86615eca2962b77a826 (diff)
TTY: serial/m32r_sio, remove debug macros
DEBUG_AUTOCONF is unused. Switch DEBUG_INTR to pr_debug. This is only enabled with DEBUG or dynamic debug when explicitly asked for. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/m32r_sio.c')
-rw-r--r--drivers/tty/serial/m32r_sio.c25
1 files changed, 5 insertions, 20 deletions
diff --git a/drivers/tty/serial/m32r_sio.c b/drivers/tty/serial/m32r_sio.c
index 835b5697a455..6b1303505667 100644
--- a/drivers/tty/serial/m32r_sio.c
+++ b/drivers/tty/serial/m32r_sio.c
@@ -49,21 +49,6 @@
49#include <linux/serial_core.h> 49#include <linux/serial_core.h>
50#include "m32r_sio_reg.h" 50#include "m32r_sio_reg.h"
51 51
52/*
53 * Debugging.
54 */
55#if 0
56#define DEBUG_AUTOCONF(fmt...) printk(fmt)
57#else
58#define DEBUG_AUTOCONF(fmt...) do { } while (0)
59#endif
60
61#if 0
62#define DEBUG_INTR(fmt...) printk(fmt)
63#else
64#define DEBUG_INTR(fmt...) do { } while (0)
65#endif
66
67#define PASS_LIMIT 256 52#define PASS_LIMIT 256
68 53
69/* Standard COM flags */ 54/* Standard COM flags */
@@ -334,7 +319,7 @@ static void receive_chars(struct uart_sio_port *up, int *status)
334 } 319 }
335 320
336 if (*status & UART_LSR_BI) { 321 if (*status & UART_LSR_BI) {
337 DEBUG_INTR("handling break...."); 322 pr_debug("handling break....\n");
338 flag = TTY_BREAK; 323 flag = TTY_BREAK;
339 } else if (*status & UART_LSR_PE) 324 } else if (*status & UART_LSR_PE)
340 flag = TTY_PARITY; 325 flag = TTY_PARITY;
@@ -395,7 +380,7 @@ static void transmit_chars(struct uart_sio_port *up)
395 if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS) 380 if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS)
396 uart_write_wakeup(&up->port); 381 uart_write_wakeup(&up->port);
397 382
398 DEBUG_INTR("THRE..."); 383 pr_debug("THRE...\n");
399 384
400 if (uart_circ_empty(xmit)) 385 if (uart_circ_empty(xmit))
401 m32r_sio_stop_tx(&up->port); 386 m32r_sio_stop_tx(&up->port);
@@ -407,7 +392,7 @@ static void transmit_chars(struct uart_sio_port *up)
407static inline void m32r_sio_handle_port(struct uart_sio_port *up, 392static inline void m32r_sio_handle_port(struct uart_sio_port *up,
408 unsigned int status) 393 unsigned int status)
409{ 394{
410 DEBUG_INTR("status = %x...", status); 395 pr_debug("status = %x...\n", status);
411 396
412 if (status & 0x04) 397 if (status & 0x04)
413 receive_chars(up, &status); 398 receive_chars(up, &status);
@@ -435,7 +420,7 @@ static irqreturn_t m32r_sio_interrupt(int irq, void *dev_id)
435 struct list_head *l, *end = NULL; 420 struct list_head *l, *end = NULL;
436 int pass_counter = 0; 421 int pass_counter = 0;
437 422
438 DEBUG_INTR("m32r_sio_interrupt(%d)...", irq); 423 pr_debug("m32r_sio_interrupt(%d)...\n", irq);
439 424
440#ifdef CONFIG_SERIAL_M32R_PLDSIO 425#ifdef CONFIG_SERIAL_M32R_PLDSIO
441// if (irq == PLD_IRQ_SIO0_SND) 426// if (irq == PLD_IRQ_SIO0_SND)
@@ -475,7 +460,7 @@ static irqreturn_t m32r_sio_interrupt(int irq, void *dev_id)
475 460
476 spin_unlock(&i->lock); 461 spin_unlock(&i->lock);
477 462
478 DEBUG_INTR("end.\n"); 463 pr_debug("end.\n");
479 464
480 return IRQ_HANDLED; 465 return IRQ_HANDLED;
481} 466}