Commit 86b525be authored by Rodolfo Giometti's avatar Rodolfo Giometti Committed by Greg Kroah-Hartman
Browse files

drivers pps: add PPS generators support



Sometimes one needs to be able not only to catch PPS signals but to
produce them also. For example, running a distributed simulation,
which requires computers' clock to be synchronized very tightly.

This patch adds PPS generators class in order to have a well-defined
interface for these devices.

Signed-off-by: default avatarRodolfo Giometti <giometti@enneenne.com>
Link: https://lore.kernel.org/r/20241108073115.759039-2-giometti@enneenne.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c79a39dc
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -283,6 +283,7 @@ Code Seq# Include File Comments
'p'   80-9F  linux/ppdev.h                                           user-space parport
                                                                     <mailto:tim@cyberelk.net>
'p'   A1-A5  linux/pps.h                                             LinuxPPS
'p'   B1-B3  linux/pps-gen.h                                         LinuxPPS
                                                                     <mailto:giometti@linux.it>
'q'   00-1F  linux/serio.h
'q'   80-FF  linux/telephony.h                                       Internet PhoneJACK, Internet LineJACK
+1 −0
Original line number Diff line number Diff line
@@ -18719,6 +18719,7 @@ F: Documentation/devicetree/bindings/pps/pps-gpio.yaml
F:	Documentation/driver-api/pps.rst
F:	drivers/pps/
F:	include/linux/pps*.h
F:	include/uapi/linux/pps-gen.h
F:	include/uapi/linux/pps.h
PRESSURE STALL INFORMATION (PSI)
+2 −1
Original line number Diff line number Diff line
@@ -6,6 +6,7 @@
pps_core-y			:= pps.o kapi.o sysfs.o
pps_core-$(CONFIG_NTP_PPS)	+= kc.o
obj-$(CONFIG_PPS)		:= pps_core.o
obj-y				+= clients/ generators/
obj-y				+= clients/
obj-$(CONFIG_PPS_GENERATOR)	+= generators/

ccflags-$(CONFIG_PPS_DEBUG) := -DDEBUG
+12 −1
Original line number Diff line number Diff line
@@ -3,7 +3,16 @@
# PPS generators configuration
#

comment "PPS generators support"
menuconfig PPS_GENERATOR
	tristate "PPS generators support"
	help
	  PPS generators are special hardware which are able to produce PPS
	  (Pulse Per Second) signals.

	  To compile this driver as a module, choose M here: the module
	  will be called pps_gen_core.

if PPS_GENERATOR

config PPS_GENERATOR_PARPORT
	tristate "Parallel port PPS signal generator"
@@ -12,3 +21,5 @@ config PPS_GENERATOR_PARPORT
	  If you say yes here you get support for a PPS signal generator which
	  utilizes STROBE pin of a parallel port to send PPS signals. It uses
	  parport abstraction layer and hrtimers to precisely control the signal.

endif # PPS_GENERATOR
+3 −0
Original line number Diff line number Diff line
@@ -3,6 +3,9 @@
# Makefile for PPS generators.
#

pps_gen_core-y			:= pps_gen.o sysfs.o
obj-$(CONFIG_PPS_GENERATOR)	:= pps_gen_core.o

obj-$(CONFIG_PPS_GENERATOR_PARPORT) += pps_gen_parport.o

ccflags-$(CONFIG_PPS_DEBUG) := -DDEBUG
Loading