[PATCH 0/8] counter: fix, improvements and stm32 timer events support

Fabrice Gasnier fabrice.gasnier at foss.st.com
Tue Aug 29 06:40:21 PDT 2023


This series combines some fix and improvements to the counter interface,
found while stm32 timer counter driver developements.
It also introduces a new tool that can be used for testing.

Then, it improves the stm32 timer counter driver by introducing new signals,
e.g. counting frequency, and missing channels.
It also adds support for interrupt based events using the chrdev interface.
Two event types are added in this series: overflows and capture.

Up to now, stm32 timer counter driver focused mainly on quadrature
encoder feature. With this series, all timer instances can be enabled
for simple counting (with overflow and capture events).

Fabrice Gasnier (8):
  counter: chrdev: fix getting array extensions
  counter: chrdev: remove a typo in header file comment
  tools/counter: add a flexible watch events tool
  mfd: stm32-timers: add support for interrupts
  counter: stm32-timer-cnt: rename quadrature signal
  counter: stm32-timer-cnt: introduce clock signal
  counter: stm32-timer-cnt: populate capture channels and check encoder
  counter: stm32-timer-cnt: add support for events

 drivers/counter/counter-chrdev.c     |   4 +-
 drivers/counter/stm32-timer-cnt.c    | 585 ++++++++++++++++++++++++++-
 drivers/mfd/stm32-timers.c           |  46 +++
 include/linux/mfd/stm32-timers.h     |  26 ++
 include/uapi/linux/counter.h         |   2 +-
 tools/counter/Build                  |   1 +
 tools/counter/Makefile               |   8 +-
 tools/counter/counter_watch_events.c | 348 ++++++++++++++++
 8 files changed, 998 insertions(+), 22 deletions(-)
 create mode 100644 tools/counter/counter_watch_events.c

-- 
2.25.1




More information about the linux-arm-kernel mailing list