Skip to contentSkip to conversation

mtd: rawnand: omap_elm: convert DT binding to yaml

PATCH Applied Roger Quadros 3 participants 8 messages Mar 26, 2022 – Apr 11, 2022

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

v3 cover mtd: rawnand: omap_elm: convert DT binding to yaml

Hi,

This series converts omap_elm DT bindings to yaml and adds support for ELM on AM64 SoC.

Changelog:
v3
- use 'enum' for compatible specifier. Get rid of 'items'.

v2
- explain hwmod usage deprecated in commit log
- fix example node name to 'ecc'
- remove 'items' for single compatible specifier

cheers,
-roger

Roger Quadros (3):
dt-bindings: mtd: ti,elm: Convert to yaml
dt-bindings: mtd: ti,elm: Add support for AM64 ELM
mtd: rawnand: omap_elm: Add compatible for AM64 ELM

 Documentation/devicetree/bindings/mtd/elm.txt | 16 -----
 .../devicetree/bindings/mtd/ti,elm.yaml       | 72 +++++++++++++++++++
 drivers/mtd/nand/raw/omap_elm.c               |  1 +
 3 files changed, 73 insertions(+), 16 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/mtd/elm.txt
 create mode 100644 Documentation/devicetree/bindings/mtd/ti,elm.yaml
Signature · 1 line
2.17.1
#1 lore raw

PATCH v3 1/3 dt-bindings: mtd: ti,elm: Convert to yaml

Convert elm.txt to ti,elm.yaml.

hwmod framework use is deprecated for new platforms so mark it so.

---
 Documentation/devicetree/bindings/mtd/elm.txt | 16 -------
 .../devicetree/bindings/mtd/ti,elm.yaml       | 48 +++++++++++++++++++
 2 files changed, 48 insertions(+), 16 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/mtd/elm.txt
 create mode 100644 Documentation/devicetree/bindings/mtd/ti,elm.yaml
Documentation/devicetree/bindings/mtd/elm.txt deleted +0 -16
deleted file mode 100644
index 59ddc61c1076..000000000000
@@ -1,16 +0,0 @@
-Error location module
-
-Required properties:
-- compatible: Must be "ti,am3352-elm"
-- reg: physical base address and size of the registers map.
-- interrupts: Interrupt number for the elm.
-
-Optional properties:
-- ti,hwmods: Name of the hwmod associated to the elm
-
-Example:
-elm: elm@0 {
-	compatible = "ti,am3352-elm";
-	reg = <0x48080000 0x2000>;
-	interrupts = <4>;
-};
Documentation/devicetree/bindings/mtd/ti,elm.yaml new file +48 -0

48 lines not on this page · raw message

Signature · 1 line
2.17.1
#3 lore raw

PATCH v3 2/3 dt-bindings: mtd: ti,elm: Add support for AM64 ELM

In reply to Roger Quadros

TI's AM64 SoC has the Error Locator Module. Add compatible and related properties to support ELM on AM64 SoC.

---
 .../devicetree/bindings/mtd/ti,elm.yaml       | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)
Documentation/devicetree/bindings/mtd/ti,elm.yaml +24 -0
index 1821395bbfb6..87128c004596 100644
@@ -18,6 +18,7 @@ properties:
   compatible:
     enum:
       - ti,am3352-elm
+      - ti,am64-elm
 
   reg:
     maxItems: 1
@@ -25,6 +26,17 @@ properties:
   interrupts:
     maxItems: 1
 
+  clocks:
+    maxItems: 1
+    description: Functional clock.
+
+  clock-names:
+    items:
+      - const: fck
+
+  power-domains:
+    maxItems: 1
+
   ti,hwmods:
     description:
       Name of the HWMOD associated with ELM. This is for legacy
@@ -37,6 +49,18 @@ required:
   - reg
   - interrupts
 
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: ti,am64-elm
+    then:
+      required:
+        - clocks
+        - clock-names
+        - power-domains
+
 additionalProperties: false
 
 examples:
Signature · 1 line
2.17.1
Reviewed-by on v3 2/3
#4 lore raw

Re: [PATCH v3 2/3] dt-bindings: mtd: ti,elm: Add support for AM64 ELM

Quoted 8 lines · Roger Quadros

TI's AM64 SoC has the Error Locator Module. Add compatible and related properties to support ELM on AM64 SoC.

---
 .../devicetree/bindings/mtd/ti,elm.yaml       | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)

Best regards,
Krzysztof

maintainer Applied
#5 lore raw

Re: [PATCH v3 2/3] dt-bindings: mtd: ti,elm: Add support for AM64 ELM

In reply to Roger Quadros
Quoted 5 lines · Roger Quadros

TI's AM64 SoC has the Error Locator Module. Add compatible and related properties to support ELM on AM64 SoC.

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git nand/next, thanks.

Miquel

#6 lore raw

PATCH v3 3/3 mtd: rawnand: omap_elm: Add compatible for AM64 ELM

In reply to Roger Quadros

The AM64 SoC has the Error Locator Module. Add compatible id for it.

---
 drivers/mtd/nand/raw/omap_elm.c | 1 +
 1 file changed, 1 insertion(+)
drivers/mtd/nand/raw/omap_elm.c +1 -0
index db105d9b560c..aa7f49c3f372 100644
@@ -550,6 +550,7 @@ static SIMPLE_DEV_PM_OPS(elm_pm_ops, elm_suspend, elm_resume);
 #ifdef CONFIG_OF
 static const struct of_device_id elm_of_match[] = {
 	{ .compatible = "ti,am3352-elm" },
+	{ .compatible = "ti,am64-elm" },
 	{},
 };
 MODULE_DEVICE_TABLE(of, elm_of_match);
Signature · 1 line
2.17.1