[PATCH v3 0/2] rs485 bus termination GPIO

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Define a device tree binding for an rs485 bus termination GPIO
(patch [1/2]), amend the serial core to retrieve the GPIO from
the device tree and amend the default ->rs485_config() callback
for 8250 drivers to change the GPIO on request from user space
(patch [2/2]).


Changes v2 -> v3:

* Patch [2/2]:
  * Drop unnecessary NULL pointer check preceding gpiod_set_value(). (Heiko)
  * Amend commit message to suggest moving 8250_exar.c to new binding. (Andy)
    Add Jan to Cc and Andy's R-b tag.

Changes v1 -> v2:

* Patch [2/2]:
  * Drop unnecessary devm_gpiod_put(). (Andy)
  * Use GPIOD_OUT_LOW macro for brevity. (Andy)
  * Document the rationale for disabling termination by default.
  * Drop nonsensical read of GPIO after setting its direction to out.


Link to v2:
https://lore.kernel.org/linux-serial/cover.1589285873.git.lukas@xxxxxxxxx


Lukas Wunner (2):
  dt-bindings: serial: Add binding for rs485 bus termination GPIO
  serial: 8250: Support rs485 bus termination GPIO

 .../devicetree/bindings/serial/rs485.yaml        |  4 ++++
 drivers/tty/serial/8250/8250_port.c              |  3 +++
 drivers/tty/serial/serial_core.c                 | 16 ++++++++++++++++
 include/linux/serial_core.h                      |  2 ++
 4 files changed, 25 insertions(+)

-- 
2.26.2




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux