lkml.org 
[lkml]   [2022]   [Jul]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH 0/2] serial: RS485 termination improvements
Date
This series improves termination handling for RS485. Effectively,
.rs485_supported is made a per port and the termination flag is enabled
when DT configures termination. The downside of this is that embedded
struct consumes a little bit of more memory, especially as struct
serial_rs485 has the padding field.

There is other problem on this area besides the one addressed by this
series which is new since the introduction of .rs485_supported. Lino's
patch series addresses the ability to tweak the termination through
->rs485_config() for any driver.

For kernel uses, struct kserial_rs485 version of serial_rs485 could be
added and both .rs485 and .rs485_supported converted to it leaving
struct_rs485 only for UAPI use. This series, howver, doesn't attempt
it. It seems relatively easy to build it on top of these changes
though.


Ilpo Järvinen (2):
serial: Embed rs485_supported
serial: RS485 termination is supported if DT provides one

drivers/tty/serial/8250/8250_bcm2835aux.c | 2 +-
drivers/tty/serial/8250/8250_dwlib.c | 4 ++--
drivers/tty/serial/8250/8250_exar.c | 2 +-
drivers/tty/serial/8250/8250_fintek.c | 4 ++--
drivers/tty/serial/8250/8250_lpc18xx.c | 2 +-
drivers/tty/serial/8250/8250_of.c | 2 +-
drivers/tty/serial/8250/8250_pci.c | 2 +-
drivers/tty/serial/amba-pl011.c | 2 +-
drivers/tty/serial/ar933x_uart.c | 4 ++--
drivers/tty/serial/atmel_serial.c | 2 +-
drivers/tty/serial/fsl_lpuart.c | 2 +-
drivers/tty/serial/imx.c | 4 ++--
drivers/tty/serial/max310x.c | 2 +-
drivers/tty/serial/mcf.c | 4 ++--
drivers/tty/serial/omap-serial.c | 2 +-
drivers/tty/serial/sc16is7xx.c | 2 +-
drivers/tty/serial/serial_core.c | 10 ++++++----
drivers/tty/serial/stm32-usart.c | 2 +-
include/linux/serial_core.h | 2 +-
19 files changed, 29 insertions(+), 27 deletions(-)

--
2.30.2

\
 
 \ /
  Last update: 2022-07-04 11:45    [W:0.047 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site