From: Conor Dooley <conor@kernel.org>
To: Matti Vaittinen <mazziesaccount@gmail.com>
Cc: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>,
Jonathan Cameron <jic23@kernel.org>,
Lars-Peter Clausen <lars@metafoo.de>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>, Nuno Sa <nuno.sa@analog.com>,
David Lechner <dlechner@baylibre.com>,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 1/5] dt-bindings: ROHM BD79124 ADC/GPO
Date: Wed, 5 Feb 2025 20:03:57 +0000 [thread overview]
Message-ID: <20250205-stalemate-shorthand-5a29fbc4081f@spud> (raw)
In-Reply-To: <4e6cd143d3e896587528a415c8623ecd610fac55.1738761899.git.mazziesaccount@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 3810 bytes --]
On Wed, Feb 05, 2025 at 03:34:29PM +0200, Matti Vaittinen wrote:
> Add binding document for the ROHM BD79124 ADC / GPO.
>
> ROHM BD79124 is a 8-channel, 12-bit ADC. The input pins can also be used
> as general purpose outputs.
>
> Signed-off-by: Matti Vaittinen <mazziesaccount@gmail.com>
> ---
> Revision history:
> RFC v1 => v2:
> - drop MFD and represent directly as ADC
> - drop pinmux and treat all non ADC channel pins as GPOs
> ---
> .../bindings/iio/adc/rohm,bd79124.yaml | 114 ++++++++++++++++++
> 1 file changed, 114 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/iio/adc/rohm,bd79124.yaml
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/rohm,bd79124.yaml b/Documentation/devicetree/bindings/iio/adc/rohm,bd79124.yaml
> new file mode 100644
> index 000000000000..50889dc6b9a8
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/rohm,bd79124.yaml
> @@ -0,0 +1,114 @@
> +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/adc/rohm,bd79124.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: ROHM BD79124 ADC/GPO
> +
> +maintainers:
> + - Matti Vaittinen <mazziesaccount@gmail.com>
> +
> +description: |
> + The ROHM BD79124 is a 12-bit, 8-channel, SAR ADC. The ADC supports
> + an automatic measurement mode, with an alarm interrupt for out-of-window
> + measurements. ADC input pins can be also configured as general purpose
> + outputs.
> +
> +properties:
> + compatible:
> + const: rohm,bd79124
> +
> + reg:
> + description:
> + I2C slave address.
> + maxItems: 1
> +
> + interrupts:
> + maxItems: 1
> +
> + gpio-controller: true
> +
> + "#gpio-cells":
> + const: 1
> + description:
> + The pin number.
> +
> + vdd-supply: true
> +
> + iovdd-supply: true
> +
> + "#address-cells":
> + const: 1
> +
> + "#size-cells":
> + const: 0
> +
> +patternProperties:
> + "^channel@[0-9a-f]+$":
You can only have 8 channels, there's no need for this to be so
permissive, right?
Otherwise, this looks good enough to me.
> + type: object
> + $ref: /schemas/iio/adc/adc.yaml#
> + description: Represents ADC channel.
> +
> + properties:
> + reg:
> + description: AIN pin number
> + minimum: 0
> + maximum: 7
> +
> + required:
> + - reg
> +
> + additionalProperties: false
> +
> +required:
> + - compatible
> + - reg
> + - iovdd-supply
> + - vdd-supply
> +
> +additionalProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/interrupt-controller/irq.h>
> + #include <dt-bindings/leds/common.h>
> + i2c {
> + #address-cells = <1>;
> + #size-cells = <0>;
> + adc: adc@10 {
> + compatible = "rohm,bd79124";
> + reg = <0x10>;
> +
> + interrupt-parent = <&gpio1>;
> + interrupts = <29 8>;
> +
> + vdd-supply = <&dummyreg>;
> + iovdd-supply = <&dummyreg>;
> +
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + channel@0 {
> + reg = <0>;
> + };
> + channel@1 {
> + reg = <1>;
> + };
> + channel@2 {
> + reg = <2>;
> + };
> + channel@3 {
> + reg = <3>;
> + };
> + channel@4 {
> + reg = <4>;
> + };
> + channel@5 {
> + reg = <5>;
> + };
> + channel@6 {
> + reg = <6>;
> + };
> + };
> + };
> --
> 2.48.1
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2025-02-05 20:04 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-05 13:34 [PATCH v2 0/5] Support ROHM BD79124 ADC/GPO Matti Vaittinen
2025-02-05 13:34 ` [PATCH v2 1/5] dt-bindings: " Matti Vaittinen
2025-02-05 20:03 ` Conor Dooley [this message]
2025-02-06 8:39 ` Matti Vaittinen
2025-02-06 18:16 ` Conor Dooley
2025-02-05 13:34 ` [PATCH v2 2/5] iio: adc: add helpers for parsing ADC nodes Matti Vaittinen
2025-02-08 16:41 ` Jonathan Cameron
2025-02-11 8:52 ` Matti Vaittinen
2025-02-11 19:07 ` Jonathan Cameron
2025-02-16 17:50 ` David Lechner
2025-02-17 6:29 ` Matti Vaittinen
2025-02-17 16:05 ` David Lechner
2025-02-17 7:08 ` Matti Vaittinen
2025-02-17 14:24 ` Matti Vaittinen
2025-02-05 13:38 ` [PATCH v2 3/5] iio: adc: Support ROHM BD79124 ADC Matti Vaittinen
2025-02-06 22:42 ` kernel test robot
2025-02-08 16:52 ` Jonathan Cameron
2025-02-11 9:06 ` Matti Vaittinen
2025-02-11 19:19 ` Jonathan Cameron
2025-02-05 13:38 ` [PATCH v2 4/5] MAINTAINERS: Add IIO ADC helpers Matti Vaittinen
2025-02-05 13:38 ` [PATCH v2 5/5] MAINTAINERS: Add ROHM BD79124 ADC/GPO Matti Vaittinen
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=20250205-stalemate-shorthand-5a29fbc4081f@spud \
--to=conor@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=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matti.vaittinen@fi.rohmeurope.com \
--cc=mazziesaccount@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