xref: /linux/drivers/counter/Kconfig (revision a1ff5a7d78a036d6c2178ee5acd6ba4946243800)
1ec8f24b7SThomas Gleixner# SPDX-License-Identifier: GPL-2.0-only
20040a390SWilliam Breathitt Gray#
30040a390SWilliam Breathitt Gray# Counter devices
40040a390SWilliam Breathitt Gray#
50040a390SWilliam Breathitt Gray
6d4284874SWilliam Breathitt Grayconfig I8254
7d4284874SWilliam Breathitt Gray	tristate
8d4284874SWilliam Breathitt Gray	select COUNTER
9d4284874SWilliam Breathitt Gray	select REGMAP
10d4284874SWilliam Breathitt Gray	help
11d4284874SWilliam Breathitt Gray	  Enables support for the i8254 interface library functions. The i8254
12d4284874SWilliam Breathitt Gray	  interface library provides functions to facilitate communication with
13d4284874SWilliam Breathitt Gray	  interfaces compatible with the venerable Intel 8254 Programmable
14d4284874SWilliam Breathitt Gray	  Interval Timer (PIT). The Intel 825x family of chips was first
15d4284874SWilliam Breathitt Gray	  released in the early 1980s but compatible interfaces are nowadays
16d4284874SWilliam Breathitt Gray	  typically found embedded in larger VLSI processing chips and FPGA
17d4284874SWilliam Breathitt Gray	  components.
18d4284874SWilliam Breathitt Gray
19d4284874SWilliam Breathitt Gray	  If built as a module its name will be i8254.
20d4284874SWilliam Breathitt Gray
219b53a134SWilliam Breathitt Graymenuconfig COUNTER
229b53a134SWilliam Breathitt Gray	tristate "Counter support"
239b53a134SWilliam Breathitt Gray	help
249b53a134SWilliam Breathitt Gray	  This enables counter device support through the Generic Counter
259b53a134SWilliam Breathitt Gray	  interface. You only need to enable this, if you also want to enable
269b53a134SWilliam Breathitt Gray	  one or more of the counter device drivers below.
279b53a134SWilliam Breathitt Gray
28f1d8a071SWilliam Breathitt Grayif COUNTER
29f1d8a071SWilliam Breathitt Gray
30f1d8a071SWilliam Breathitt Grayconfig 104_QUAD_8
31f1d8a071SWilliam Breathitt Gray	tristate "ACCES 104-QUAD-8 driver"
3295c211f0SWilliam Breathitt Gray	depends on (PC104 && X86) || COMPILE_TEST
3367d91a1eSNiklas Schnelle	depends on HAS_IOPORT_MAP
34f1d8a071SWilliam Breathitt Gray	select ISA_BUS_API
3598ffe025SWilliam Breathitt Gray	select REGMAP_MMIO
36f1d8a071SWilliam Breathitt Gray	help
37f1d8a071SWilliam Breathitt Gray	  Say yes here to build support for the ACCES 104-QUAD-8 quadrature
38f1d8a071SWilliam Breathitt Gray	  encoder counter/interface device family (104-QUAD-8, 104-QUAD-4).
39f1d8a071SWilliam Breathitt Gray
40f1d8a071SWilliam Breathitt Gray	  A counter's respective error flag may be cleared by performing a write
41a4ec431fSWilliam Breathitt Gray	  operation on the respective count value attribute. The 104-QUAD-8
42a4ec431fSWilliam Breathitt Gray	  counters may be set either directly or via the counter's preset
43a4ec431fSWilliam Breathitt Gray	  attribute.
44f1d8a071SWilliam Breathitt Gray
45f1d8a071SWilliam Breathitt Gray	  The base port addresses for the devices may be configured via the base
467aa2ba0dSWilliam Breathitt Gray	  array module parameter. The interrupt line numbers for the devices may
477aa2ba0dSWilliam Breathitt Gray	  be configured via the irq array module parameter.
48f1d8a071SWilliam Breathitt Gray
49a3b9a999SPatrick Havelangeconfig FTM_QUADDEC
50a3b9a999SPatrick Havelange	tristate "Flex Timer Module Quadrature decoder driver"
513760b49aSPeter Robinson	depends on SOC_LS1021A || COMPILE_TEST
520c75376fSPatrick Havelange	depends on HAS_IOMEM && OF
53a3b9a999SPatrick Havelange	help
54a3b9a999SPatrick Havelange	  Select this option to enable the Flex Timer Quadrature decoder
55a3b9a999SPatrick Havelange	  driver.
56a3b9a999SPatrick Havelange
57a3b9a999SPatrick Havelange	  To compile this driver as a module, choose M here: the
58a3b9a999SPatrick Havelange	  module will be called ftm-quaddec.
59a3b9a999SPatrick Havelange
609c5e51f2SPeter Robinsonconfig INTEL_QEP
619c5e51f2SPeter Robinson	tristate "Intel Quadrature Encoder Peripheral driver"
6292a33370SPeter Robinson	depends on X86
639c5e51f2SPeter Robinson	depends on PCI
649c5e51f2SPeter Robinson	help
659c5e51f2SPeter Robinson	  Select this option to enable the Intel Quadrature Encoder Peripheral
669c5e51f2SPeter Robinson	  driver.
679c5e51f2SPeter Robinson
689c5e51f2SPeter Robinson	  To compile this driver as a module, choose M here: the module
699c5e51f2SPeter Robinson	  will be called intel-qep.
709c5e51f2SPeter Robinson
719c5e51f2SPeter Robinsonconfig INTERRUPT_CNT
729c5e51f2SPeter Robinson	tristate "Interrupt counter driver"
739c5e51f2SPeter Robinson	depends on GPIOLIB
749c5e51f2SPeter Robinson	help
759c5e51f2SPeter Robinson	  Select this option to enable interrupt counter driver. Any interrupt
769c5e51f2SPeter Robinson	  source can be used by this driver as the event source.
779c5e51f2SPeter Robinson
789c5e51f2SPeter Robinson	  To compile this driver as a module, choose M here: the
799c5e51f2SPeter Robinson	  module will be called interrupt-cnt.
809c5e51f2SPeter Robinson
81106b1041SKamel Bouharaconfig MICROCHIP_TCB_CAPTURE
82106b1041SKamel Bouhara	tristate "Microchip Timer Counter Capture driver"
8301f714eeSLukas Bulwahn	depends on SOC_AT91SAM9 || SOC_SAM_V7 || COMPILE_TEST
84106b1041SKamel Bouhara	depends on HAS_IOMEM && OF
85106b1041SKamel Bouhara	select REGMAP_MMIO
86106b1041SKamel Bouhara	help
87106b1041SKamel Bouhara	  Select this option to enable the Microchip Timer Counter Block
88106b1041SKamel Bouhara	  capture driver.
89106b1041SKamel Bouhara
90106b1041SKamel Bouhara	  To compile this driver as a module, choose M here: the
91106b1041SKamel Bouhara	  module will be called microchip-tcb-capture.
92106b1041SKamel Bouhara
930be89073SBiju Dasconfig RZ_MTU3_CNT
940be89073SBiju Das	tristate "Renesas RZ/G2L MTU3a counter driver"
9510d33404SArnd Bergmann	depends on RZ_MTU3
960be89073SBiju Das	help
970be89073SBiju Das	  Enable support for MTU3a counter driver found on Renesas RZ/G2L alike
980be89073SBiju Das	  SoCs. This IP supports both 16-bit and 32-bit phase counting mode
990be89073SBiju Das	  support.
1000be89073SBiju Das
1010be89073SBiju Das	  To compile this driver as a module, choose M here: the
1020be89073SBiju Das	  module will be called rz-mtu3-cnt.
1030be89073SBiju Das
1049c5e51f2SPeter Robinsonconfig STM32_LPTIMER_CNT
1059c5e51f2SPeter Robinson	tristate "STM32 LP Timer encoder counter driver"
1069c5e51f2SPeter Robinson	depends on MFD_STM32_LPTIMER || COMPILE_TEST
107b711f687SJarkko Nikula	help
1089c5e51f2SPeter Robinson	  Select this option to enable STM32 Low-Power Timer quadrature encoder
1099c5e51f2SPeter Robinson	  and counter driver.
110b711f687SJarkko Nikula
1119c5e51f2SPeter Robinson	  To compile this driver as a module, choose M here: the
1129c5e51f2SPeter Robinson	  module will be called stm32-lptimer-cnt.
1139c5e51f2SPeter Robinson
1149c5e51f2SPeter Robinsonconfig STM32_TIMER_CNT
1159c5e51f2SPeter Robinson	tristate "STM32 Timer encoder counter driver"
1169c5e51f2SPeter Robinson	depends on MFD_STM32_TIMERS || COMPILE_TEST
1179c5e51f2SPeter Robinson	help
1189c5e51f2SPeter Robinson	  Select this option to enable STM32 Timer quadrature encoder
1199c5e51f2SPeter Robinson	  and counter driver.
1209c5e51f2SPeter Robinson
1219c5e51f2SPeter Robinson	  To compile this driver as a module, choose M here: the
1229c5e51f2SPeter Robinson	  module will be called stm32-timer-cnt.
123b711f687SJarkko Nikula
1244e2f42aaSJulien Panisconfig TI_ECAP_CAPTURE
1254e2f42aaSJulien Panis	tristate "TI eCAP capture driver"
1264e2f42aaSJulien Panis	depends on ARCH_OMAP2PLUS || ARCH_DAVINCI_DA8XX || ARCH_KEYSTONE || ARCH_K3 || COMPILE_TEST
1274e2f42aaSJulien Panis	depends on HAS_IOMEM
1284e2f42aaSJulien Panis	select REGMAP_MMIO
1294e2f42aaSJulien Panis	help
1304e2f42aaSJulien Panis	  Select this option to enable the Texas Instruments Enhanced Capture
1314e2f42aaSJulien Panis	  (eCAP) driver in input mode.
1324e2f42aaSJulien Panis
1334e2f42aaSJulien Panis	  It can be used to timestamp events (falling/rising edges) detected
1344e2f42aaSJulien Panis	  on ECAP input signal.
1354e2f42aaSJulien Panis
1364e2f42aaSJulien Panis	  To compile this driver as a module, choose M here: the module
1374e2f42aaSJulien Panis	  will be called ti-ecap-capture.
1384e2f42aaSJulien Panis
1399c5e51f2SPeter Robinsonconfig TI_EQEP
1409c5e51f2SPeter Robinson	tristate "TI eQEP counter driver"
141*988609f2SJudith Mendez	depends on SOC_AM33XX || ARCH_K3 || COMPILE_TEST
1429c5e51f2SPeter Robinson	select REGMAP_MMIO
1439c5e51f2SPeter Robinson	help
1449c5e51f2SPeter Robinson	  Select this option to enable the Texas Instruments Enhanced Quadrature
1459c5e51f2SPeter Robinson	  Encoder Pulse (eQEP) counter driver.
1469c5e51f2SPeter Robinson
1479c5e51f2SPeter Robinson	  To compile this driver as a module, choose M here: the module will be
1489c5e51f2SPeter Robinson	  called ti-eqep.
1499c5e51f2SPeter Robinson
150f1d8a071SWilliam Breathitt Grayendif # COUNTER
151