The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Wadim Mueller <wafgo01@gmail.com>
To: "Jonathan Cameron" <jic23@kernel.org>,
	"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
	"Rob Herring" <robh@kernel.org>,
	"Conor Dooley" <conor+dt@kernel.org>,
	"David Lechner" <dlechner@baylibre.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	"Andy Shevchenko" <andy@kernel.org>,
	"Maxwell Doose" <m32285159@gmail.com>
Cc: linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Marcelo Schmitt <marcelo.schmitt1@gmail.com>,
	Rodrigo Alencar <455.rodrigo.alencar@gmail.com>,
	Wadim Mueller <wafgo01@gmail.com>
Subject: [PATCH v4 0/4] iio: flow: Sensirion SLF3S liquid flow sensor
Date: Thu, 11 Jun 2026 15:26:56 +0200	[thread overview]
Message-ID: <20260611132700.671322-1-wafgo01@gmail.com> (raw)

Hi all,

this series adds a driver for the Sensirion SLF3S family of I2C liquid
flow sensors (SLF3S-0600F / -1300F / -4000B) and a new IIO_VOLUMEFLOW
channel type.  As in v3 this is posted as a fresh thread.

Dependency
----------
The volume-flow scale is reported in m^3/s as a 64-bit fixed-point value
(IIO_VAL_DECIMAL64_FEMTO), so this series depends on Rodrigo Alencar's
"ADF41513/ADF41510 PLL frequency synthesizers" series, which adds the
IIO_VAL_DECIMAL64_* core formatting (and the kstrtodec64() and
div64_s64_rem() helpers it builds on):

  https://lore.kernel.org/linux-iio/20260604-adf41513-iio-driver-v16-0-1a7d09143bc2@analog.com/

Patch 3/4 adds the IIO_VAL_DECIMAL64_FEMTO format type on top of that.

Changes since v3
----------------
  * volumeflow unit switched from l/s to m^3/s (SI), per Jonathan
  * scale now reported as IIO_VAL_DECIMAL64_FEMTO instead of
    IIO_VAL_FRACTIONAL, so the small m^3/s values (~1.7e-12 m^3/s for the
    SLF3S-0600F) keep full precision; this needs the new FEMTO core type
    (3/4) and the dependency above
  * dt-bindings: sensirion,slf3s-1300f now serves as the fallback
    compatible for the other variants (all variants are detectable from
    the product-information register), per Krzysztof; Marcelo's
    Reviewed-by dropped because of this change
  * dt-bindings: add interrupts (maxItems: 1) back
  * dt-bindings: reflow the description to 80 columns
  * dt-bindings: move "F: drivers/iio/flow/slf3s.c" to the driver patch
  * driver: add system PM ops following the scd30/scd4x precedent: stop
    the measurement and disable the supply on suspend; power back up,
    wait out the power-up time and restart with the previously active
    medium on resume
  * driver: if switching the medium fails after the stop command, restart
    with the previous medium instead of leaving the sensor idle
  * driver: a sensor reporting an unknown sub-type now falls back to the
    variant named in the device tree instead of failing probe, matching
    the fallback-compatible semantics
  * driver: serialise the command/response exchanges with a local mutex
    instead of iio_device_claim_direct() / release_direct()
  * driver: issue a stop-measurement at the start of probe(), so a sensor
    left in continuous mode across a warm reboot does not NACK probe
  * driver: read only the 6 bytes actually used (flow + temperature) per
    measurement frame instead of 9
  * driver: trim the per-variant list out of the Kconfig help text
  * ABI: in_volumeflow_medium[_available] documented in
    Documentation/ABI/testing/sysfs-bus-iio-flow; KernelVersion 7.3

The signaling-flags word (air-in-line / high-flow / smoothing status) in
each measurement frame is intentionally not read; exposing it can be a
later follow-up.

Thanks,
Wadim

Wadim Mueller (4):
  iio: types: add IIO_VOLUMEFLOW channel type
  dt-bindings: iio: flow: add Sensirion SLF3S liquid flow sensor
  iio: core: add IIO_VAL_DECIMAL64_FEMTO format type
  iio: flow: add Sensirion SLF3S liquid flow sensor driver

 Documentation/ABI/testing/sysfs-bus-iio       |  11 +
 Documentation/ABI/testing/sysfs-bus-iio-flow  |  21 +
 .../bindings/iio/flow/sensirion,slf3s.yaml    |  58 ++
 MAINTAINERS                                   |   8 +
 drivers/iio/Kconfig                           |   1 +
 drivers/iio/Makefile                          |   1 +
 drivers/iio/flow/Kconfig                      |  22 +
 drivers/iio/flow/Makefile                     |   7 +
 drivers/iio/flow/slf3s.c                      | 521 ++++++++++++++++++
 drivers/iio/industrialio-core.c               |   3 +
 include/linux/iio/types.h                     |   1 +
 include/uapi/linux/iio/types.h                |   1 +
 tools/iio/iio_event_monitor.c                 |   2 +
 13 files changed, 657 insertions(+)
 create mode 100644 Documentation/ABI/testing/sysfs-bus-iio-flow
 create mode 100644 Documentation/devicetree/bindings/iio/flow/sensirion,slf3s.yaml
 create mode 100644 drivers/iio/flow/Kconfig
 create mode 100644 drivers/iio/flow/Makefile
 create mode 100644 drivers/iio/flow/slf3s.c


base-commit: 3cd8b194bf3428dfa53120fee47e827a7c495815
prerequisite-patch-id: b51a25b69f7b78155e78d1a3aab809bcb57e11ae
prerequisite-patch-id: 1b26fb01ab41218c214fa58657305437565c06f8
prerequisite-patch-id: 7745e957a25b8673c7f838a9ae7a55269cd21798
prerequisite-patch-id: 5f805ccb0be820042ac732d0d8e1b188bfd2b2bc
prerequisite-patch-id: 80967f95ecb0c10fc66b3d073e99906126d5b40b
prerequisite-patch-id: 729fdedcf2055c506693d28a5dab65a6a3791598
-- 
2.52.0


             reply	other threads:[~2026-06-11 13:27 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-11 13:26 Wadim Mueller [this message]
2026-06-11 13:26 ` [PATCH v4 1/4] iio: types: add IIO_VOLUMEFLOW channel type Wadim Mueller
2026-06-11 13:26 ` [PATCH v4 2/4] dt-bindings: iio: flow: add Sensirion SLF3S liquid flow sensor Wadim Mueller
2026-06-11 14:01   ` Krzysztof Kozlowski
2026-06-11 13:26 ` [PATCH v4 3/4] iio: core: add IIO_VAL_DECIMAL64_FEMTO format type Wadim Mueller
2026-06-12  9:11   ` Rodrigo Alencar
2026-06-11 13:27 ` [PATCH v4 4/4] iio: flow: add Sensirion SLF3S liquid flow sensor driver Wadim Mueller
2026-06-11 14:01   ` Krzysztof Kozlowski
2026-06-12 17:47     ` Jonathan Cameron
2026-06-13  7:51       ` Krzysztof Kozlowski
2026-06-14 15:10         ` Jonathan Cameron
2026-06-15  4:27           ` Krzysztof Kozlowski
2026-06-21 13:51             ` Jonathan Cameron
2026-07-08  6:50               ` Wadim Mueller
2026-06-11 19:18   ` Andy Shevchenko
2026-06-14 15:19   ` Jonathan Cameron

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260611132700.671322-1-wafgo01@gmail.com \
    --to=wafgo01@gmail.com \
    --cc=455.rodrigo.alencar@gmail.com \
    --cc=andy@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dlechner@baylibre.com \
    --cc=jic23@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m32285159@gmail.com \
    --cc=marcelo.schmitt1@gmail.com \
    --cc=nuno.sa@analog.com \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox