All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/7] Add support for QCOM SPMI PMIC5 Gen4 ADC
@ 2026-11-20  9:19 Jishnu Prakash
  2026-11-20  9:19 ` [PATCH v2 1/7] dt-bindings: iio: adc: Add "qcom,adc5-gen4" property for ADC channels Jishnu Prakash
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Jishnu Prakash @ 2026-11-20  9:19 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Amit Kucheria,
	Thara Gopinath, Rafael J. Wysocki, Daniel Lezcano, Zhang Rui,
	Lukasz Luba
  Cc: linux-iio, devicetree, linux-kernel, linux-arm-msm, linux-pm,
	Kamal Wadhwa, Anjelique Melendez,
	Manaf Meethalavalappu Pallikunhi, Priyansh Jain, Jishnu Prakash,
	Andy Shevchenko

PMIC5 Gen4 ADC is the next generation following PMIC5 Gen3 ADC, with
several hardware changes for improved performance. In software
implementation, it is mostly similar to Gen3 ADC with the following
key differences:

- Increased ratiometric conversion resolution from 14 bits to 16 bits.
- Extended SID field from 4 to 5 bits and addition of a 2-bit bus index
  field in the SID register, to support communication with up to 32 PMICs
  per bus across up to 4 buses under the latest PMIC arbiter (v8).

This series adds support for the PMIC5 Gen4 ADC:

Patches 1, 3 and 4 add the dt-bindings, IIO ADC driver, and thermal ADC-TM
driver support respectively within the existing files, to support
Gen4 ADC channels under existing master PMICs with Gen3 ADC peripheral.

Patch 2 is a fix to explicitly assign any enum values used in hardware
to avoid issues later from enum modifications in the middle.

Patch 5 is a cleanup to remove Gen3 virtual channel macros after they
have been updated in both the IIO ADC and thermal ADC-TM drivers.

Patches 6 and 7 add the dt-bindings and IIO ADC driver support for
having a master PMIC with Gen4 ADC (with channels under it being Gen4 by
default).

DT patches have been dropped from this series, they will be sent in a
separate series.

Signed-off-by: Jishnu Prakash <jishnu.prakash@oss.qualcomm.com>
---
Changes in v2:
- Made following changes to address comments from Jonathan:
  - Split documentation and IIO driver patches to first add support for Gen4
    ADC channels under master PMICs with Gen3 ADC peripheral, and then
    remaining Gen4 support, for master PMICs with Gen4 ADC peripheral.
  - Reversed order of if() checks in adc5_gen3_read_voltage_data.
  - Avoided moving adc5_match_table.
  - Made formatting fixes in adc5_gen4_chans_pmic and other places to
    keep code on a single line.
- Added patch to explicitly assign enums used in HW as Andy suggested.
- Added a cleanup patch to remove replaced ADC Gen3 virtual channel macros.
- Added kernel-doc comments for new members added to struct
  adc5_channel_common_prop.
- Link to v1: https://patch.msgid.link/20260731-pmic5_gen4_adc-v1-0-9c49b2eea6f9@oss.qualcomm.com

---
Jishnu Prakash (7):
      dt-bindings: iio: adc: Add "qcom,adc5-gen4" property for ADC channels
      iio: adc: qcom-adc5-gen3: Explicitly assign enum values used in hardware
      iio: adc: qcom-spmi-adc5-gen3: Add support for QCOM PMIC5 Gen4 ADC
      thermal: qcom: qcom-spmi-adc-tm5-gen3: Add support for QCOM PMIC5 Gen4 ADC
      iio: adc: qcom-spmi-adc5-gen3: Remove Gen3 virtual channel macros
      dt-bindings: iio: adc: Add support for QCOM PMIC5 Gen4 ADC
      iio: adc: qcom-spmi-adc5-gen3: Add support for Gen4 ADC master PMICs

 .../bindings/iio/adc/qcom,spmi-adc5-gen3.yaml      |  47 +++++++-
 drivers/iio/adc/qcom-spmi-adc5-gen3.c              | 133 +++++++++++++++------
 drivers/iio/adc/qcom-vadc-common.c                 |  41 +++++++
 drivers/thermal/qcom/qcom-spmi-adc-tm5-gen3.c      |  19 ++-
 include/linux/iio/adc/qcom-adc5-gen3-common.h      |  59 +++++++--
 include/linux/iio/adc/qcom-vadc-common.h           |   6 +
 6 files changed, 251 insertions(+), 54 deletions(-)
---
base-commit: aebb7274476403040d582c61478df8f4a7bf9cd3
change-id: 20260730-pmic5_gen4_adc-f33d756bba5c

Best regards,
--  
Jishnu Prakash <jishnu.prakash@oss.qualcomm.com>


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

end of thread, other threads:[~2026-11-20 10:14 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-20  9:19 [PATCH v2 0/7] Add support for QCOM SPMI PMIC5 Gen4 ADC Jishnu Prakash
2026-11-20  9:19 ` [PATCH v2 1/7] dt-bindings: iio: adc: Add "qcom,adc5-gen4" property for ADC channels Jishnu Prakash
2026-11-20  9:19 ` [PATCH v2 2/7] iio: adc: qcom-adc5-gen3: Explicitly assign enum values used in hardware Jishnu Prakash
2026-11-20  9:19 ` [PATCH v2 3/7] iio: adc: qcom-spmi-adc5-gen3: Add support for QCOM PMIC5 Gen4 ADC Jishnu Prakash
2026-11-20  9:35   ` sashiko-bot
2026-11-20 10:14   ` Andy Shevchenko
2026-11-20  9:19 ` [PATCH v2 4/7] thermal: qcom: qcom-spmi-adc-tm5-gen3: " Jishnu Prakash
2026-11-20  9:19 ` [PATCH v2 5/7] iio: adc: qcom-spmi-adc5-gen3: Remove Gen3 virtual channel macros Jishnu Prakash
2026-11-20  9:19 ` [PATCH v2 6/7] dt-bindings: iio: adc: Add support for QCOM PMIC5 Gen4 ADC Jishnu Prakash
2026-11-20  9:19 ` [PATCH v2 7/7] iio: adc: qcom-spmi-adc5-gen3: Add support for Gen4 ADC master PMICs Jishnu Prakash

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.