The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [PATCH v1 0/2] iio: adc: add MAX40080 current-sense amplifier driver
@ 2026-07-03 10:29 Stefan Popa
  2026-07-03 10:29 ` [PATCH v1 1/2] dt-bindings: iio: adc: add maxim,max40080 Stefan Popa
                   ` (2 more replies)
  0 siblings, 3 replies; 17+ messages in thread
From: Stefan Popa @ 2026-07-03 10:29 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: David Lechner, Nuno Sá, Andy Shevchenko, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Ciprian Hegbeli, linux-iio,
	devicetree, linux-kernel, Stefan Popa

This series adds support for the Maxim MAX40080, a bidirectional
current-sense amplifier with an integrated 12-bit ADC and an I2C/SMBus
interface. It measures the voltage across an external shunt resistor and
the input bus voltage.

The driver operates in direct (INDIO_DIRECT_MODE) mode. Each raw read
triggers a single on-demand conversion (SMBus Quick Command) and reads
back the matched current/voltage pair, so results are always fresh. It
exposes the current and voltage channels with raw and scale attributes,
a configurable oversampling (digital averaging) ratio, and PEC-protected
register access. The two selectable current-sense ranges are exposed
through scale/scale_available (the range is chosen by writing the
desired scale); the current scale is derived from the
shunt-resistor-micro-ohms device-tree property.

Continuous FIFO buffering, threshold events and the alert interrupt are
intentionally left out of this initial submission and may be added
later.

Tested on hardware with four MAX40080 devices on an I2C bus.

Patch 1 adds the device-tree binding; patch 2 adds the driver.

Stefan Popa (2):
  dt-bindings: iio: adc: add maxim,max40080
  iio: adc: add MAX40080 current-sense amplifier driver

 .../bindings/iio/adc/maxim,max40080.yaml      |  55 ++
 MAINTAINERS                                   |   9 +
 drivers/iio/adc/Kconfig                       |  11 +
 drivers/iio/adc/Makefile                      |   1 +
 drivers/iio/adc/max40080.c                    | 587 ++++++++++++++++++
 5 files changed, 663 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/iio/adc/maxim,max40080.yaml
 create mode 100644 drivers/iio/adc/max40080.c

-- 
2.51.0


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2026-07-04 18:53 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-03 10:29 [PATCH v1 0/2] iio: adc: add MAX40080 current-sense amplifier driver Stefan Popa
2026-07-03 10:29 ` [PATCH v1 1/2] dt-bindings: iio: adc: add maxim,max40080 Stefan Popa
2026-07-03 16:21   ` Conor Dooley
2026-07-03 20:42   ` David Lechner
2026-07-03 10:29 ` [PATCH v1 2/2] iio: adc: add MAX40080 current-sense amplifier driver Stefan Popa
2026-07-03 12:08   ` Andy Shevchenko
2026-07-03 23:36     ` Jonathan Cameron
2026-07-03 19:42   ` Siratul Islam
2026-07-03 20:29     ` David Lechner
2026-07-04 12:05     ` Andy Shevchenko
2026-07-04 16:32       ` Siratul Islam
2026-07-04 17:05         ` Andy Shevchenko
2026-07-04 17:30           ` Siratul Islam
2026-07-04 18:52             ` Andy Shevchenko
2026-07-03 21:04   ` David Lechner
2026-07-03 23:53   ` Jonathan Cameron
2026-07-03 11:34 ` [PATCH v1 0/2] " Andy Shevchenko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox