Linux-mmc Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] dt-bindings: mmc: Convert sdhci-sirf to json-schema
@ 2020-07-06 17:43 Kangmin Park
  2020-07-15 22:06 ` Rob Herring
  0 siblings, 1 reply; 2+ messages in thread
From: Kangmin Park @ 2020-07-06 17:43 UTC (permalink / raw)
  To: Ulf Hansson
  Cc: Rob Herring, linux-mmc, devicetree, linux-arm-kernel, linux-kernel

Convert the sdhci-sirf binding to DT schema format using json-schema.

At the same time, fix unit address to match the first address specified
in the reg property of the node.

Signed-off-by: Kangmin Park <l4stpr0gr4m@gmail.com>
---
 .../devicetree/bindings/mmc/sdhci-sirf.txt    | 18 ---------
 .../devicetree/bindings/mmc/sdhci-sirf.yaml   | 40 +++++++++++++++++++
 2 files changed, 40 insertions(+), 18 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/mmc/sdhci-sirf.txt
 create mode 100644 Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml

diff --git a/Documentation/devicetree/bindings/mmc/sdhci-sirf.txt b/Documentation/devicetree/bindings/mmc/sdhci-sirf.txt
deleted file mode 100644
index dd6ed464bcb8..000000000000
--- a/Documentation/devicetree/bindings/mmc/sdhci-sirf.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-* SiRFprimII/marco/atlas6 SDHCI Controller
-
-This file documents differences between the core properties in mmc.txt
-and the properties used by the sdhci-sirf driver.
-
-Required properties:
-- compatible: sirf,prima2-sdhc
-
-Optional properties:
-- cd-gpios: card detect gpio, with zero flags.
-
-Example:
-
-	sd0: sdhci@56000000 {
-		compatible = "sirf,prima2-sdhc";
-		reg = <0xcd000000 0x100000>;
-		cd-gpios = <&gpio 6 0>;
-	};
diff --git a/Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml b/Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml
new file mode 100644
index 000000000000..46269378d9b6
--- /dev/null
+++ b/Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml
@@ -0,0 +1,40 @@
+# SPDX-License-Identifier: GPL-2.0-only
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mmc/sdhci-sirf.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Sdhci Sirf Device Tree Bindings
+
+description: |
+  This file documents differences between the core properties in
+  mmc.txt and the properties used by the sdhci-sirf driver.
+
+maintainers:
+  - Ulf Hansson <ulf.hansson@linaro.org>
+
+properties:
+  compatible:
+    enum:
+      - sirf,prima2-sdhc
+
+  reg:
+    maxItems: 1
+
+  cd-gpios:
+    description:
+      card detect gpio, with zero flags.
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    sd0: sdhci@cd000000 {
+          compatible = "sirf,prima2-sdhc";
+          reg = <0xcd000000 0x100000>;
+          cd-gpios = <&gpio 6 0>;
+    };
-- 
2.26.2


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] dt-bindings: mmc: Convert sdhci-sirf to json-schema
  2020-07-06 17:43 [PATCH] dt-bindings: mmc: Convert sdhci-sirf to json-schema Kangmin Park
@ 2020-07-15 22:06 ` Rob Herring
  0 siblings, 0 replies; 2+ messages in thread
From: Rob Herring @ 2020-07-15 22:06 UTC (permalink / raw)
  To: Kangmin Park
  Cc: Ulf Hansson, linux-mmc, devicetree, linux-arm-kernel, linux-kernel

On Tue, Jul 07, 2020 at 02:43:36AM +0900, Kangmin Park wrote:
> Convert the sdhci-sirf binding to DT schema format using json-schema.
> 
> At the same time, fix unit address to match the first address specified
> in the reg property of the node.
> 
> Signed-off-by: Kangmin Park <l4stpr0gr4m@gmail.com>
> ---
>  .../devicetree/bindings/mmc/sdhci-sirf.txt    | 18 ---------
>  .../devicetree/bindings/mmc/sdhci-sirf.yaml   | 40 +++++++++++++++++++
>  2 files changed, 40 insertions(+), 18 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/mmc/sdhci-sirf.txt
>  create mode 100644 Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml
> 
> diff --git a/Documentation/devicetree/bindings/mmc/sdhci-sirf.txt b/Documentation/devicetree/bindings/mmc/sdhci-sirf.txt
> deleted file mode 100644
> index dd6ed464bcb8..000000000000
> --- a/Documentation/devicetree/bindings/mmc/sdhci-sirf.txt
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -* SiRFprimII/marco/atlas6 SDHCI Controller
> -
> -This file documents differences between the core properties in mmc.txt
> -and the properties used by the sdhci-sirf driver.
> -
> -Required properties:
> -- compatible: sirf,prima2-sdhc
> -
> -Optional properties:
> -- cd-gpios: card detect gpio, with zero flags.
> -
> -Example:
> -
> -	sd0: sdhci@56000000 {
> -		compatible = "sirf,prima2-sdhc";
> -		reg = <0xcd000000 0x100000>;
> -		cd-gpios = <&gpio 6 0>;
> -	};
> diff --git a/Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml b/Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml
> new file mode 100644
> index 000000000000..46269378d9b6
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/mmc/sdhci-sirf.yaml
> @@ -0,0 +1,40 @@
> +# SPDX-License-Identifier: GPL-2.0-only
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/mmc/sdhci-sirf.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Sdhci Sirf Device Tree Bindings
> +
> +description: |
> +  This file documents differences between the core properties in
> +  mmc.txt and the properties used by the sdhci-sirf driver.
> +
> +maintainers:
> +  - Ulf Hansson <ulf.hansson@linaro.org>

Normally, this should be someone familar with the h/w, not the MMC 
maintainer.

Needs a reference to mmc-controller.yaml. 

> +
> +properties:
> +  compatible:
> +    enum:
> +      - sirf,prima2-sdhc
> +
> +  reg:
> +    maxItems: 1
> +
> +  cd-gpios:
> +    description:
> +      card detect gpio, with zero flags.
> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    sd0: sdhci@cd000000 {
> +          compatible = "sirf,prima2-sdhc";
> +          reg = <0xcd000000 0x100000>;
> +          cd-gpios = <&gpio 6 0>;
> +    };
> -- 
> 2.26.2
> 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-06 17:43 [PATCH] dt-bindings: mmc: Convert sdhci-sirf to json-schema Kangmin Park
2020-07-15 22:06 ` Rob Herring

Linux-mmc Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-mmc/0 linux-mmc/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-mmc linux-mmc/ https://lore.kernel.org/linux-mmc \
		linux-mmc@vger.kernel.org
	public-inbox-index linux-mmc

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-mmc


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git