lkml.org 
[lkml]   [2022]   [Aug]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v2 2/2] serial: dz: Remove custom DZ_WAKEUP_CHARS
Date
Almost all serial drivers use WAKEUP_CHARS (256) from serial_core.h which
also matches what n_tty_poll() uses for asserting EPOLLOUT.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
---
drivers/tty/serial/dz.c | 2 +-
drivers/tty/serial/dz.h | 3 ---
2 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/tty/serial/dz.c b/drivers/tty/serial/dz.c
index 5d2588f3e6a9..5df46f22abaa 100644
--- a/drivers/tty/serial/dz.c
+++ b/drivers/tty/serial/dz.c
@@ -283,7 +283,7 @@ static inline void dz_transmit_chars(struct dz_mux *mux)
dz_out(dport, DZ_TDR, tmp);
dport->port.icount.tx++;

- if (uart_circ_chars_pending(xmit) < DZ_WAKEUP_CHARS)
+ if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS)
uart_write_wakeup(&dport->port);

/* Are we are done. */
diff --git a/drivers/tty/serial/dz.h b/drivers/tty/serial/dz.h
index 3b3e31954f24..4b502bfad560 100644
--- a/drivers/tty/serial/dz.h
+++ b/drivers/tty/serial/dz.h
@@ -124,7 +124,4 @@

#define DZ_NB_PORT 4

-#define DZ_XMIT_SIZE 4096 /* buffer size */
-#define DZ_WAKEUP_CHARS DZ_XMIT_SIZE/4
-
#endif /* DZ_SERIAL_H */
--
2.30.2
\
 
 \ /
  Last update: 2022-08-25 15:18    [W:0.225 / U:0.164 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site