Linux IIO development
 help / color / mirror / Atom feed
* [PATCH v2 0/5] iio: light: gp2ap020a00f: Add VCC supply and GP2AP030A00F support
@ 2026-11-08 21:43 Linus Walleij
  2026-11-08 21:43 ` [PATCH v2 1/5] dt-bindings: iio: light: sharp,gp2ap020a00f: Add VCC supply Linus Walleij
                   ` (4 more replies)
  0 siblings, 5 replies; 13+ messages in thread
From: Linus Walleij @ 2026-11-08 21:43 UTC (permalink / raw)
  To: linux-iio, Jonathan Cameron, David Lechner, Nuno Sá,
	Andy Shevchenko, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Kyungmin Park
  Cc: devicetree, Linus Walleij

Describe and enable the optional VCC supply for the GP2AP020A00F and
GP2AP030A00F. Preserve compatibility with existing device trees that only
describe the LED supply.

Extend the existing binding and driver to support the GP2AP030A00F. It
shares the register layout, but has different proximity resolution
encodings and no automatic lux calculation. Select model-specific
initialization, keep reserved bits clear and expose fixed-range raw
clear and infrared counts. Keep generic supply handling in separate
patches from the model-specific binding and driver additions.

Assisted by LLM.

Signed-off-by: Linus Walleij <linusw@kernel.org>
---
Changes in v2:
- Replace vdd/vio with one optional vcc supply, matching the VCC pin.
- Use devm_regulator_get_enable() for VCC, allowing dummy regulators.
- Move the VLED description into the generic supply binding patch.
- Split variant infrastructure from GP2AP030A00F support.
- Use "GP2AP020A00F and similar" in family descriptions.
- Use reverse Christmas tree ordering for local declarations.
- Explicitly select MANUAL_CALC when automatic ALS calculation is absent.
- Reject missing chip match data before accessing the device.
- Use fsleep() for the GP2AP030A00F startup delay.
- Select static channel arrays and counts through chip_info.
- Link to v1: https://patch.msgid.link/20261108-gp2ap030-v1-0-55314eb7055b@kernel.org

---
Linus Walleij (5):
      dt-bindings: iio: light: sharp,gp2ap020a00f: Add VCC supply
      dt-bindings: iio: light: sharp,gp2ap020a00f: Add GP2AP030A00F
      iio: light: gp2ap020a00f: Enable the VCC supply
      iio: light: gp2ap020a00f: Prepare for chip variants
      iio: light: gp2ap020a00f: Add GP2AP030A00F support

 .../bindings/iio/light/sharp,gp2ap020a00f.yaml     |  17 ++-
 drivers/iio/light/Kconfig                          |   6 +-
 drivers/iio/light/gp2ap020a00f.c                   | 136 +++++++++++++++++++--
 3 files changed, 143 insertions(+), 16 deletions(-)
---
base-commit: 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4
change-id: 20261107-gp2ap030-99504c2dc038

Best regards,
--  
Linus Walleij <linusw@kernel.org>


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

end of thread, other threads:[~2026-11-09 23:17 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-08 21:43 [PATCH v2 0/5] iio: light: gp2ap020a00f: Add VCC supply and GP2AP030A00F support Linus Walleij
2026-11-08 21:43 ` [PATCH v2 1/5] dt-bindings: iio: light: sharp,gp2ap020a00f: Add VCC supply Linus Walleij
2026-11-09 12:54   ` Krzysztof Kozlowski
2026-11-08 21:44 ` [PATCH v2 2/5] dt-bindings: iio: light: sharp,gp2ap020a00f: Add GP2AP030A00F Linus Walleij
2026-11-09 12:54   ` Krzysztof Kozlowski
2026-11-08 21:44 ` [PATCH v2 3/5] iio: light: gp2ap020a00f: Enable the VCC supply Linus Walleij
2026-11-09  9:21   ` Joshua Crofts
2026-11-08 21:44 ` [PATCH v2 4/5] iio: light: gp2ap020a00f: Prepare for chip variants Linus Walleij
2026-11-09  9:20   ` Joshua Crofts
2026-11-09 23:14   ` Andy Shevchenko
2026-11-08 21:44 ` [PATCH v2 5/5] iio: light: gp2ap020a00f: Add GP2AP030A00F support Linus Walleij
2026-11-09  9:25   ` Joshua Crofts
2026-11-09 23:17   ` Andy Shevchenko

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