1ec8f24b7SThomas Gleixner# SPDX-License-Identifier: GPL-2.0-only 20040a390SWilliam Breathitt Gray# 30040a390SWilliam Breathitt Gray# Counter devices 40040a390SWilliam Breathitt Gray# 50040a390SWilliam Breathitt Gray 60040a390SWilliam Breathitt Graymenuconfig COUNTER 70040a390SWilliam Breathitt Gray tristate "Counter support" 80040a390SWilliam Breathitt Gray help 90040a390SWilliam Breathitt Gray This enables counter device support through the Generic Counter 100040a390SWilliam Breathitt Gray interface. You only need to enable this, if you also want to enable 110040a390SWilliam Breathitt Gray one or more of the counter device drivers below. 12f1d8a071SWilliam Breathitt Gray 13f1d8a071SWilliam Breathitt Grayif COUNTER 14f1d8a071SWilliam Breathitt Gray 15f1d8a071SWilliam Breathitt Grayconfig 104_QUAD_8 16f1d8a071SWilliam Breathitt Gray tristate "ACCES 104-QUAD-8 driver" 1795c211f0SWilliam Breathitt Gray depends on (PC104 && X86) || COMPILE_TEST 18f1d8a071SWilliam Breathitt Gray select ISA_BUS_API 19f1d8a071SWilliam Breathitt Gray help 20f1d8a071SWilliam Breathitt Gray Say yes here to build support for the ACCES 104-QUAD-8 quadrature 21f1d8a071SWilliam Breathitt Gray encoder counter/interface device family (104-QUAD-8, 104-QUAD-4). 22f1d8a071SWilliam Breathitt Gray 23f1d8a071SWilliam Breathitt Gray A counter's respective error flag may be cleared by performing a write 24f1d8a071SWilliam Breathitt Gray operation on the respective count value attribute. Although the 25f1d8a071SWilliam Breathitt Gray 104-QUAD-8 counters have a 25-bit range, only the lower 24 bits may be 267aa2ba0dSWilliam Breathitt Gray set, either directly or via the counter's preset attribute. 27f1d8a071SWilliam Breathitt Gray 28f1d8a071SWilliam Breathitt Gray The base port addresses for the devices may be configured via the base 297aa2ba0dSWilliam Breathitt Gray array module parameter. The interrupt line numbers for the devices may 307aa2ba0dSWilliam Breathitt Gray be configured via the irq array module parameter. 31f1d8a071SWilliam Breathitt Gray 32a3b9a999SPatrick Havelangeconfig FTM_QUADDEC 33a3b9a999SPatrick Havelange tristate "Flex Timer Module Quadrature decoder driver" 343760b49aSPeter Robinson depends on SOC_LS1021A || COMPILE_TEST 350c75376fSPatrick Havelange depends on HAS_IOMEM && OF 36a3b9a999SPatrick Havelange help 37a3b9a999SPatrick Havelange Select this option to enable the Flex Timer Quadrature decoder 38a3b9a999SPatrick Havelange driver. 39a3b9a999SPatrick Havelange 40a3b9a999SPatrick Havelange To compile this driver as a module, choose M here: the 41a3b9a999SPatrick Havelange module will be called ftm-quaddec. 42a3b9a999SPatrick Havelange 439c5e51f2SPeter Robinsonconfig INTEL_QEP 449c5e51f2SPeter Robinson tristate "Intel Quadrature Encoder Peripheral driver" 4592a33370SPeter Robinson depends on X86 469c5e51f2SPeter Robinson depends on PCI 479c5e51f2SPeter Robinson help 489c5e51f2SPeter Robinson Select this option to enable the Intel Quadrature Encoder Peripheral 499c5e51f2SPeter Robinson driver. 509c5e51f2SPeter Robinson 519c5e51f2SPeter Robinson To compile this driver as a module, choose M here: the module 529c5e51f2SPeter Robinson will be called intel-qep. 539c5e51f2SPeter Robinson 549c5e51f2SPeter Robinsonconfig INTERRUPT_CNT 559c5e51f2SPeter Robinson tristate "Interrupt counter driver" 569c5e51f2SPeter Robinson depends on GPIOLIB 579c5e51f2SPeter Robinson help 589c5e51f2SPeter Robinson Select this option to enable interrupt counter driver. Any interrupt 599c5e51f2SPeter Robinson source can be used by this driver as the event source. 609c5e51f2SPeter Robinson 619c5e51f2SPeter Robinson To compile this driver as a module, choose M here: the 629c5e51f2SPeter Robinson module will be called interrupt-cnt. 639c5e51f2SPeter Robinson 64106b1041SKamel Bouharaconfig MICROCHIP_TCB_CAPTURE 65106b1041SKamel Bouhara tristate "Microchip Timer Counter Capture driver" 6601f714eeSLukas Bulwahn depends on SOC_AT91SAM9 || SOC_SAM_V7 || COMPILE_TEST 67106b1041SKamel Bouhara depends on HAS_IOMEM && OF 68106b1041SKamel Bouhara select REGMAP_MMIO 69106b1041SKamel Bouhara help 70106b1041SKamel Bouhara Select this option to enable the Microchip Timer Counter Block 71106b1041SKamel Bouhara capture driver. 72106b1041SKamel Bouhara 73106b1041SKamel Bouhara To compile this driver as a module, choose M here: the 74106b1041SKamel Bouhara module will be called microchip-tcb-capture. 75106b1041SKamel Bouhara 76*0be89073SBiju Dasconfig RZ_MTU3_CNT 77*0be89073SBiju Das tristate "Renesas RZ/G2L MTU3a counter driver" 78*0be89073SBiju Das depends on RZ_MTU3 || COMPILE_TEST 79*0be89073SBiju Das help 80*0be89073SBiju Das Enable support for MTU3a counter driver found on Renesas RZ/G2L alike 81*0be89073SBiju Das SoCs. This IP supports both 16-bit and 32-bit phase counting mode 82*0be89073SBiju Das support. 83*0be89073SBiju Das 84*0be89073SBiju Das To compile this driver as a module, choose M here: the 85*0be89073SBiju Das module will be called rz-mtu3-cnt. 86*0be89073SBiju Das 879c5e51f2SPeter Robinsonconfig STM32_LPTIMER_CNT 889c5e51f2SPeter Robinson tristate "STM32 LP Timer encoder counter driver" 899c5e51f2SPeter Robinson depends on MFD_STM32_LPTIMER || COMPILE_TEST 90b711f687SJarkko Nikula help 919c5e51f2SPeter Robinson Select this option to enable STM32 Low-Power Timer quadrature encoder 929c5e51f2SPeter Robinson and counter driver. 93b711f687SJarkko Nikula 949c5e51f2SPeter Robinson To compile this driver as a module, choose M here: the 959c5e51f2SPeter Robinson module will be called stm32-lptimer-cnt. 969c5e51f2SPeter Robinson 979c5e51f2SPeter Robinsonconfig STM32_TIMER_CNT 989c5e51f2SPeter Robinson tristate "STM32 Timer encoder counter driver" 999c5e51f2SPeter Robinson depends on MFD_STM32_TIMERS || COMPILE_TEST 1009c5e51f2SPeter Robinson help 1019c5e51f2SPeter Robinson Select this option to enable STM32 Timer quadrature encoder 1029c5e51f2SPeter Robinson and counter driver. 1039c5e51f2SPeter Robinson 1049c5e51f2SPeter Robinson To compile this driver as a module, choose M here: the 1059c5e51f2SPeter Robinson module will be called stm32-timer-cnt. 106b711f687SJarkko Nikula 1074e2f42aaSJulien Panisconfig TI_ECAP_CAPTURE 1084e2f42aaSJulien Panis tristate "TI eCAP capture driver" 1094e2f42aaSJulien Panis depends on ARCH_OMAP2PLUS || ARCH_DAVINCI_DA8XX || ARCH_KEYSTONE || ARCH_K3 || COMPILE_TEST 1104e2f42aaSJulien Panis depends on HAS_IOMEM 1114e2f42aaSJulien Panis select REGMAP_MMIO 1124e2f42aaSJulien Panis help 1134e2f42aaSJulien Panis Select this option to enable the Texas Instruments Enhanced Capture 1144e2f42aaSJulien Panis (eCAP) driver in input mode. 1154e2f42aaSJulien Panis 1164e2f42aaSJulien Panis It can be used to timestamp events (falling/rising edges) detected 1174e2f42aaSJulien Panis on ECAP input signal. 1184e2f42aaSJulien Panis 1194e2f42aaSJulien Panis To compile this driver as a module, choose M here: the module 1204e2f42aaSJulien Panis will be called ti-ecap-capture. 1214e2f42aaSJulien Panis 1229c5e51f2SPeter Robinsonconfig TI_EQEP 1239c5e51f2SPeter Robinson tristate "TI eQEP counter driver" 1249c5e51f2SPeter Robinson depends on (SOC_AM33XX || COMPILE_TEST) 1259c5e51f2SPeter Robinson select REGMAP_MMIO 1269c5e51f2SPeter Robinson help 1279c5e51f2SPeter Robinson Select this option to enable the Texas Instruments Enhanced Quadrature 1289c5e51f2SPeter Robinson Encoder Pulse (eQEP) counter driver. 1299c5e51f2SPeter Robinson 1309c5e51f2SPeter Robinson To compile this driver as a module, choose M here: the module will be 1319c5e51f2SPeter Robinson called ti-eqep. 1329c5e51f2SPeter Robinson 133f1d8a071SWilliam Breathitt Grayendif # COUNTER 134