diff mbox series

[1/2] dt-bindings: input: sun4i-lradc-keys: add R329 LRADC binding

Message ID BYAPR20MB2472D625C876D97E95CB6078BCF79@BYAPR20MB2472.namprd20.prod.outlook.com (mailing list archive)
State New
Headers show
Series [1/2] dt-bindings: input: sun4i-lradc-keys: add R329 LRADC binding | expand

Commit Message

icenowy@outlook.com April 22, 2022, 4:07 p.m. UTC
From: Icenowy Zheng <icenowy@sipeed.com>

R329 has similar LRADC with previous Allwinner SoCs, but with bus clock
and reset.

Add binding for it.

Signed-off-by: Icenowy Zheng <icenowy@sipeed.com>
---
 .../input/allwinner,sun4i-a10-lradc-keys.yaml | 21 +++++++++++++++++++
 1 file changed, 21 insertions(+)

Comments

Rob Herring April 22, 2022, 9:10 p.m. UTC | #1
On Sat, 23 Apr 2022 00:07:43 +0800, icenowy@outlook.com wrote:
> From: Icenowy Zheng <icenowy@sipeed.com>
> 
> R329 has similar LRADC with previous Allwinner SoCs, but with bus clock
> and reset.
> 
> Add binding for it.
> 
> Signed-off-by: Icenowy Zheng <icenowy@sipeed.com>
> ---
>  .../input/allwinner,sun4i-a10-lradc-keys.yaml | 21 +++++++++++++++++++
>  1 file changed, 21 insertions(+)
> 

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.yaml: then:properties:required: ['clocks', 'resets'] is not of type 'object', 'boolean'
	from schema $id: http://json-schema.org/draft-07/schema#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.yaml: ignoring, error in schema: then: properties: required
Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.example.dtb:0:0: /example-0/lradc@1c22800: failed to match any schema with compatible: ['allwinner,sun4i-a10-lradc-keys']

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit.
Samuel Holland April 22, 2022, 11:28 p.m. UTC | #2
Hi Icenowy,

On 4/22/22 11:07 AM, icenowy@outlook.com wrote:
> From: Icenowy Zheng <icenowy@sipeed.com>
> 
> R329 has similar LRADC with previous Allwinner SoCs, but with bus clock
> and reset.
> 
> Add binding for it.
> 
> Signed-off-by: Icenowy Zheng <icenowy@sipeed.com>

I sent this binding/driver update (also with D1 support) last week:

https://lore.kernel.org/lkml/20220414002349.24332-1-samuel@sholland.org/T/

Please see if it works for you.

Regards,
Samuel
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.yaml b/Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.yaml
index d74f2002409e..e16f01510ea7 100644
--- a/Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.yaml
+++ b/Documentation/devicetree/bindings/input/allwinner,sun4i-a10-lradc-keys.yaml
@@ -15,6 +15,7 @@  properties:
     oneOf:
       - const: allwinner,sun4i-a10-lradc-keys
       - const: allwinner,sun8i-a83t-r-lradc
+      - const: allwinner,sun50i-r329-lradc
       - items:
           - const: allwinner,sun50i-a64-lradc
           - const: allwinner,sun8i-a83t-r-lradc
@@ -31,6 +32,26 @@  properties:
 
   wakeup-source: true
 
+if:
+  properties:
+    compatible:
+      const: allwinner,sun50i-r329-lradc
+then:
+  properties:
+    clocks:
+      description:
+        Bus clock gate for LRADC.
+      maxItems: 1
+
+    resets:
+      description:
+        Bus reset for LRADC.
+      maxItems: 1
+
+    required:
+      - clocks
+      - resets
+
 patternProperties:
   "^button-[0-9]+$":
     type: object