When reviewing the various SPMI PMIC bindings, I noticed that several
examples were incorrect and misleading and could also use some cleanup.
This series addresses the iio/adc ones.
Johan
Johan Hovold (6):
dt-bindings: iio/adc: qcom,spmi-iadc: fix reg description
dt-bindings: iio/adc: qcom,spmi-iadc: fix example node name
dt-bindings: iio/adc: qcom,spmi-iadc: clean up example
dt-bindings: iio/adc: qcom,spmi-rradc: clean up example
dt-bindings: iio/adc: qcom,spmi-vadc: fix example node names
dt-bindings: iio/adc: qcom,spmi-vadc: clean up examples
.../devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml | 10 ++++++----
.../devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml | 4 ++--
.../devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml | 9 +++++----
3 files changed, 13 insertions(+), 10 deletions(-)
--
2.41.0
The IADC is a child of an SPMI PMIC, which in turn sits on an SPMI bus.
Fixes: a4e6bf69418c ("dt-bindings:iio:adc:qcom,spmi-iadc: txt to yaml format conversion.")
Signed-off-by: Johan Hovold <[email protected]>
---
Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
index e0e0aa9d5d5b..16889d2d3575 100644
--- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
@@ -50,7 +50,8 @@ additionalProperties: false
examples:
- |
#include <dt-bindings/interrupt-controller/irq.h>
- spmi {
+
+ pmic {
#address-cells = <1>;
#size-cells = <0>;
pmic_iadc: adc@3600 {
--
2.41.0
The IADC register is just the base address in the SPMI PMIC and does not
include any length.
Signed-off-by: Johan Hovold <[email protected]>
---
Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
index 73def67fbe01..e0e0aa9d5d5b 100644
--- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
@@ -25,7 +25,7 @@ properties:
- const: qcom,spmi-iadc
reg:
- description: IADC base address and length in the SPMI PMIC register map
+ description: IADC base address in the SPMI PMIC register map
maxItems: 1
qcom,external-resistor-micro-ohms:
--
2.41.0
The VADC is a child of an SPMI PMIC, which in turn sits on an SPMI bus.
Fixes: 74e903461b17 ("dt-bindings: iio: adc: qcom,spmi-vadc: extend example")
Fixes: 5a471662b5d9 ("iio: adc: Convert the QCOM SPMI ADC bindings to .yaml format")
Signed-off-by: Johan Hovold <[email protected]>
---
Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
index ad7d6fc49de5..eb02715bf691 100644
--- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
@@ -236,7 +236,7 @@ additionalProperties: false
examples:
- |
- spmi {
+ pmic {
#address-cells = <1>;
#size-cells = <0>;
/* VADC node */
@@ -281,7 +281,7 @@ examples:
#include <dt-bindings/iio/qcom,spmi-adc7-pm8350.h>
#include <dt-bindings/interrupt-controller/irq.h>
- spmi {
+ pmic {
#address-cells = <1>;
#size-cells = <0>;
adc@3100 {
--
2.41.0
Clean up the IADC example by adding a newline separator, dropping an
unnecessary label and removing stray white space.
Signed-off-by: Johan Hovold <[email protected]>
---
.../devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
index 16889d2d3575..5ed893ef5c18 100644
--- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml
@@ -54,12 +54,13 @@ examples:
pmic {
#address-cells = <1>;
#size-cells = <0>;
- pmic_iadc: adc@3600 {
+
+ adc@3600 {
compatible = "qcom,pm8941-iadc", "qcom,spmi-iadc";
reg = <0x3600>;
interrupts = <0x0 0x36 0x0 IRQ_TYPE_EDGE_RISING>;
qcom,external-resistor-micro-ohms = <10000>;
- #io-channel-cells = <1>;
+ #io-channel-cells = <1>;
};
};
...
--
2.41.0
Clean up the VADC examples by dropping a comment, dropping unnecessary
labels and adding newline separators.
Signed-off-by: Johan Hovold <[email protected]>
---
.../devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
index eb02715bf691..40fa0710f1f0 100644
--- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
@@ -239,8 +239,8 @@ examples:
pmic {
#address-cells = <1>;
#size-cells = <0>;
- /* VADC node */
- pmic_vadc: adc@3100 {
+
+ adc@3100 {
compatible = "qcom,spmi-vadc";
reg = <0x3100>;
interrupts = <0x0 0x31 0x0 0x1>;
@@ -284,6 +284,7 @@ examples:
pmic {
#address-cells = <1>;
#size-cells = <0>;
+
adc@3100 {
reg = <0x3100>;
compatible = "qcom,spmi-adc7";
--
2.41.0
Clean up the RRADC example by dropping an unnecessary label and removing
stray white space.
Signed-off-by: Johan Hovold <[email protected]>
---
.../devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml
index b3a626389870..f39bc92c2b99 100644
--- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml
@@ -43,9 +43,9 @@ examples:
#address-cells = <1>;
#size-cells = <0>;
- pmic_rradc: adc@4500 {
+ adc@4500 {
compatible = "qcom,pmi8998-rradc";
reg = <0x4500>;
- #io-channel-cells = <1>;
+ #io-channel-cells = <1>;
};
};
--
2.41.0
On Thu, 30 Nov 2023 18:16:22 +0100
Johan Hovold <[email protected]> wrote:
> When reviewing the various SPMI PMIC bindings, I noticed that several
> examples were incorrect and misleading and could also use some cleanup.
>
> This series addresses the iio/adc ones.
All look fine to me. Just waiting for the DT folk to have time to take a look.
>
> Johan
>
>
> Johan Hovold (6):
> dt-bindings: iio/adc: qcom,spmi-iadc: fix reg description
> dt-bindings: iio/adc: qcom,spmi-iadc: fix example node name
> dt-bindings: iio/adc: qcom,spmi-iadc: clean up example
> dt-bindings: iio/adc: qcom,spmi-rradc: clean up example
> dt-bindings: iio/adc: qcom,spmi-vadc: fix example node names
> dt-bindings: iio/adc: qcom,spmi-vadc: clean up examples
>
> .../devicetree/bindings/iio/adc/qcom,spmi-iadc.yaml | 10 ++++++----
> .../devicetree/bindings/iio/adc/qcom,spmi-rradc.yaml | 4 ++--
> .../devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml | 9 +++++----
> 3 files changed, 13 insertions(+), 10 deletions(-)
>
On Mon, Dec 04, 2023 at 01:26:24PM +0000, Jonathan Cameron wrote:
> On Thu, 30 Nov 2023 18:16:22 +0100
> Johan Hovold <[email protected]> wrote:
>
> > When reviewing the various SPMI PMIC bindings, I noticed that several
> > examples were incorrect and misleading and could also use some cleanup.
> >
> > This series addresses the iio/adc ones.
>
> All look fine to me. Just waiting for the DT folk to have time to take a look.
Yah, they all look grand to me.
Acked-by: Conor Dooley <[email protected]>
Cheers,
Conor.
On Mon, 4 Dec 2023 16:25:34 +0000
Conor Dooley <[email protected]> wrote:
> On Mon, Dec 04, 2023 at 01:26:24PM +0000, Jonathan Cameron wrote:
> > On Thu, 30 Nov 2023 18:16:22 +0100
> > Johan Hovold <[email protected]> wrote:
> >
> > > When reviewing the various SPMI PMIC bindings, I noticed that several
> > > examples were incorrect and misleading and could also use some cleanup.
> > >
> > > This series addresses the iio/adc ones.
> >
> > All look fine to me. Just waiting for the DT folk to have time to take a look.
>
> Yah, they all look grand to me.
> Acked-by: Conor Dooley <[email protected]>
>
> Cheers,
> Conor.
Applied. Thanks,
J