Thread (9 messages) 9 messages, 3 authors, 2023-01-03

RE: [PATCH v2 1/4] dt-bindings: mfd: Add nxp bbnsm

From: Jacky Bai <ping.bai@nxp.com>
Date: 2022-12-27 01:54:39
Also in: linux-arm-kernel, linux-devicetree, linux-rtc

Hi Rob,
Subject: Re: [PATCH v2 1/4] dt-bindings: mfd: Add nxp bbnsm

On Mon, Dec 26, 2022 at 10:39:39AM +0800, Jacky Bai wrote:
quoted
Add binding for NXP BBNSM(Battery-Backed Non-Secure Module).

Signed-off-by: Jacky Bai <ping.bai@nxp.com>
---
  - v2 changes:
    - remove the redundant 'bindings' string
    - add ref to rtc.yaml
    - add start-year property
    - rename 'regmap' to 'nxp,bbnsm-regmap' and add description & type
define
quoted
    - add header files including in the example and correct the
indentation
---
+
+      nxp,bbnsm-regmap:
+        $ref: /schemas/types.yaml#/definitions/phandle
+        description:
+          phandle of the bbnsm node
You don't need this now, it's the parent node.
Thx for review. yes, it is redundant, will remove it and refine the code in V3.

BR
quoted
+
+      interrupts:
+        maxItems: 1
+
+      start-year: true
+
+    required:
+      - compatible
+      - nxp,bbnsm-regmap
+      - interrupts
+
+    additionalProperties: false
+
+  pwrkey:
+    type: object
+    $ref: /schemas/input/input.yaml#
+
+    properties:
+      compatible:
+        const: nxp,bbnsm-pwrkey
+
+      nxp,bbnsm-regmap:
+        $ref: /schemas/types.yaml#/definitions/phandle
+        description:
+          phandle of the bbnsm node
Same here.
quoted
+
+      interrupts:
+        maxItems: 1
+
+      linux,code: true
+
+    required:
+      - compatible
+      - nxp,bbnsm-regmap
+      - interrupts
+
+    additionalProperties: false
+
+required:
+  - compatible
+  - reg
+  - rtc
+  - pwrkey
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/input/linux-event-codes.h>
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+
+    bbnsm: bbnsm@44440000 {
+        compatible = "nxp,bbnsm", "syscon", "simple-mfd";
+        reg = <0x44440000 0x10000>;
+
+        bbnsm_rtc: rtc {
+            compatible = "nxp,bbnsm-rtc";
+            nxp,bbnsm-regmap = <&bbnsm>;
+            interrupts = <GIC_SPI 73 IRQ_TYPE_LEVEL_HIGH>;
+        };
+
+        bbnsm_pwrkey: pwrkey {
+            compatible = "nxp,bbnsm-pwrkey";
+            nxp,bbnsm-regmap = <&bbnsm>;
+            interrupts = <GIC_SPI 73 IRQ_TYPE_LEVEL_HIGH>;
+            linux,code = <KEY_POWER>;
+        };
+    };
--
2.37.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help