]> git.baikalelectronics.ru Git - kernel.git/commit
serial:serial_core: Allow use of CTS for PPS line discipline
authorSteve Sakoman <steve@sakoman.com>
Thu, 20 Sep 2018 19:20:34 +0000 (09:20 -1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 2 Oct 2018 20:38:55 +0000 (13:38 -0700)
commit6d3fdd9b442dbcf79df71c1f4bbf85f36c85826d
treeb799d0991c3aa188982b1bcdacd263b406e39f77
parentcb76946247c9955298c990d7fdc02c942e89a876
serial:serial_core: Allow use of CTS for PPS line discipline

Add a "pps_4wire" file to serial ports in sysfs in case the kernel is
configured with CONFIG_PPS_CLIENT_LDISC. Writing 1 to the file enables
the use of CTS instead of DCD for PPS signal input. This is necessary
in case a serial port is not completely wired.
Though this affects PPS processing the patch is against the serial core
as the source of the serial port PPS event dispatching has to be
modified. Furthermore it should be possible to modify the source of
serial port PPS event dispatching before changing the line discipline.

Signed-off-by: Andreas Steinmetz <ast@domdv.de>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Tested-by: Steve Sakoman <steve@sakoman.com>
Tested-by: Eric Gallimore <egallimore@ucsd.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Documentation/ABI/testing/sysfs-tty
drivers/tty/serial/serial_core.c
include/linux/serial_core.h