linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/9] Fixes and cleanup for RS485
@ 2022-07-03 17:00 Lino Sanfilippo
  2022-07-03 17:00 ` [PATCH v2 1/9] serial: core: only get RS485 termination GPIO if supported Lino Sanfilippo
                   ` (8 more replies)
  0 siblings, 9 replies; 25+ messages in thread
From: Lino Sanfilippo @ 2022-07-03 17:00 UTC (permalink / raw)
  To: gregkh, jirislaby
  Cc: ilpo.jarvinen, robh+dt, krzysztof.kozlowski+dt, andriy.shevchenko,
	vz, linux-arm-kernel, devicetree, linux-serial, linux-kernel,
	lukas, p.rosenberger, Lino Sanfilippo

From: Lino Sanfilippo <l.sanfilippo@kunbus.com>

The following series includes cleanup and fixes around RS485 in the serial
core and uart drivers:

Patch 1: Only request the rs485 termination gpio if it is supported.
	 NOTE: 
	 This patch follows the design decision that "rs485_supported" is
	 set by the driver at initialization and cannot be modified
	 afterwards. However the better approach would be to let the serial
	 core modify the termination GPIO support setting based on the
	 existence of a termination GPIO. If "rs485_supported" is not a 
	 read-only value any more in future the logic implemented in this
	 patch should be adjusted accordingly.
Patch 2: Set the rs485 termination GPIO in the serial core. This is needed
	 since if the gpio is only accessible in sleepable context. It also
	 is a further step to make the RS485 handling more generic.
Patch 3: Move sanitizing of RS485 delays into an own function. This is in 
	 preparation of patch 4.
Patch 4: Sanitize RS485 delays read from device tree.
Patch 5: Correct RS485 delays in binding documentation.
Patch 6: Remove redundant code in 8250_dwlib.
Patch 7: Fix check for RS485 support.
Patch 8: Remove redundant code in ar933x.
Patch 9: Remove redundant code in 8250-lpc18xx.

Changes in v2:
- print a warning if termination GPIO is specified in DT/ACPI but is not
  supported by driver 
- fixed commit message for devtree documentation (as suggested by Andy)
- fixed code comment
- added patch 7


Lino Sanfilippo (9):
  serial: core: only get RS485 termination GPIO if supported
  serial: core, 8250: set RS485 termination gpio in serial core
  serial: core: move sanitizing of RS485 delays into own function
  serial: core: sanitize RS485 delays read from device tree
  dt_bindings: rs485: Correct delay values
  serial: 8250_dwlib: remove redundant sanity check for RS485 flags
  serial: ar933x: Fix check for RS485 support
  serial: ar933x: Remove redundant assignment in rs485_config
  serial: 8250: lpc18xx: Remove redundant sanity check for RS485 flags

 .../devicetree/bindings/serial/rs485.yaml     |  4 +-
 drivers/tty/serial/8250/8250_dwlib.c          | 10 +--
 drivers/tty/serial/8250/8250_lpc18xx.c        |  6 +-
 drivers/tty/serial/8250/8250_port.c           |  3 -
 drivers/tty/serial/ar933x_uart.c              | 18 ++---
 drivers/tty/serial/serial_core.c              | 70 +++++++++++++------
 6 files changed, 60 insertions(+), 51 deletions(-)


base-commit: 7349660438603ed19282e75949561406531785a5
-- 
2.25.1

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2022-07-05 20:39 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-03 17:00 [PATCH v2 0/9] Fixes and cleanup for RS485 Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 1/9] serial: core: only get RS485 termination GPIO if supported Lino Sanfilippo
2022-07-03 18:27   ` Andy Shevchenko
2022-07-04  9:01     ` Lino Sanfilippo
2022-07-04  9:55   ` Ilpo Järvinen
2022-07-04 15:07     ` Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 2/9] serial: core, 8250: set RS485 termination gpio in serial core Lino Sanfilippo
2022-07-03 18:31   ` Andy Shevchenko
2022-07-04  9:25     ` Lino Sanfilippo
2022-07-04  9:51   ` Ilpo Järvinen
2022-07-04 15:13     ` Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 3/9] serial: core: move sanitizing of RS485 delays into own function Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 4/9] serial: core: sanitize RS485 delays read from device tree Lino Sanfilippo
2022-07-03 18:34   ` Andy Shevchenko
2022-07-04  9:08     ` Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 5/9] dt_bindings: rs485: Correct delay values Lino Sanfilippo
2022-07-03 18:36   ` Andy Shevchenko
2022-07-05 20:38   ` Rob Herring
2022-07-03 17:00 ` [PATCH v2 6/9] serial: 8250_dwlib: remove redundant sanity check for RS485 flags Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 7/9] serial: ar933x: Fix check for RS485 support Lino Sanfilippo
2022-07-03 18:39   ` Andy Shevchenko
2022-07-04  9:21     ` Lino Sanfilippo
2022-07-04  9:53       ` Ilpo Järvinen
2022-07-03 17:00 ` [PATCH v2 8/9] serial: ar933x: Remove redundant assignment in rs485_config Lino Sanfilippo
2022-07-03 17:00 ` [PATCH v2 9/9] serial: 8250: lpc18xx: Remove redundant sanity check for RS485 flags Lino Sanfilippo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).