From: Conor Dooley <conor@kernel.org>
To: Charan Pedumuru <charan.pedumuru@gmail.com>
Cc: Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Thomas Bogendoerfer <tsbogend@alpha.franken.de>,
Ulf Hansson <ulf.hansson@linaro.org>,
devicetree@vger.kernel.org, linux-mips@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org
Subject: Re: [PATCH 2/2] dt-binding: mmc: microchip,sdhci-pic32: convert text based binding to json schema
Date: Thu, 8 May 2025 16:04:23 +0100 [thread overview]
Message-ID: <20250508-study-pursuable-05ea1564c9cd@spud> (raw)
In-Reply-To: <20250507-mchp-sdhci-v1-2-ed29de05295a@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 4527 bytes --]
On Wed, May 07, 2025 at 06:29:36AM +0000, Charan Pedumuru wrote:
> Update text binding to YAML.
> Changes during conversion:
> Add appropriate include statements for interrupts and clock-names
> to resolve errors identified by `dt_binding_check` and `dtbs_check`.
>
> Signed-off-by: Charan Pedumuru <charan.pedumuru@gmail.com>
> ---
> .../bindings/mmc/microchip,sdhci-pic32.txt | 29 ----------
> .../bindings/mmc/microchip,sdhci-pic32.yaml | 66 ++++++++++++++++++++++
> 2 files changed, 66 insertions(+), 29 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.txt b/Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.txt
> deleted file mode 100644
> index f064528effed31f30d1d1c6e0b49c02e215d99af..0000000000000000000000000000000000000000
> --- a/Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.txt
> +++ /dev/null
> @@ -1,29 +0,0 @@
> -* Microchip PIC32 SDHCI Controller
> -
> -This file documents differences between the core properties in mmc.txt
> -and the properties used by the sdhci-pic32 driver.
> -
> -Required properties:
> -- compatible: Should be "microchip,pic32mzda-sdhci"
> -- interrupts: Should contain interrupt
> -- clock-names: Should be "base_clk", "sys_clk".
> - See: Documentation/devicetree/bindings/resource-names.txt
> -- clocks: Phandle to the clock.
> - See: Documentation/devicetree/bindings/clock/clock-bindings.txt
> -- pinctrl-names: A pinctrl state names "default" must be defined.
> -- pinctrl-0: Phandle referencing pin configuration of the SDHCI controller.
> - See: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
> -
> -Example:
> -
> - sdhci@1f8ec000 {
> - compatible = "microchip,pic32mzda-sdhci";
> - reg = <0x1f8ec000 0x100>;
> - interrupts = <191 IRQ_TYPE_LEVEL_HIGH>;
> - clocks = <&rootclk REF4CLK>, <&rootclk PB5CLK>;
> - clock-names = "base_clk", "sys_clk";
> - bus-width = <4>;
> - cap-sd-highspeed;
> - pinctrl-names = "default";
> - pinctrl-0 = <&pinctrl_sdhc1>;
> - };
> diff --git a/Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.yaml b/Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.yaml
> new file mode 100644
> index 0000000000000000000000000000000000000000..ca0ca7df9ee991d8402bc4c62b1235ef5db2e85f
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.yaml
> @@ -0,0 +1,66 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/mmc/microchip,sdhci-pic32.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Microchip PIC32 SDHI Controller
> +
> +description:
> + The Microchip PIC32 family of microcontrollers (MCUs) includes models with
> + Secure Digital Host Controller Interface (SDHCI) controllers, allowing them
> + to interface with Secure Digital (SD) cards. This interface is used for reading,
> + writing, and managing data on SD cards, enabling storage and data transfer
> + capabilities in embedded systems.
> +
> +allOf:
> + - $ref: mmc-controller.yaml
> +
> +maintainers:
> + - Ulf Hansson <ulf.hansson@linaro.org>
> +
> +properties:
> + compatible:
> + const: microchip,pic32mzda-sdhci
> +
> + reg:
> + maxItems: 1
> +
> + interrupts:
> + maxItems: 1
> +
> + clocks:
> + maxItems: 2
> +
> + clock-names:
> + items:
> + - const: base_clk
> + - const: sys_clk
> +
> +required:
> + - compatible
> + - reg
> + - interrupts
> + - clocks
> + - clock-names
> + - pinctrl-names
> + - pinctrl-0
In a similar conversion for the platform, Rob dropped these from
required. I think you could probably do the same here.
Either way,
Acked-by: Conor Dooley <conor.dooley@microchip.com>
> +
> +unevaluatedProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/interrupt-controller/irq.h>
> + #include <dt-bindings/clock/microchip,pic32-clock.h>
> + mmc@1f8ec000 {
> + compatible = "microchip,pic32mzda-sdhci";
> + reg = <0x1f8ec000 0x100>;
> + interrupts = <191 IRQ_TYPE_LEVEL_HIGH>;
> + clocks = <&rootclk REF4CLK>, <&rootclk PB5CLK>;
> + clock-names = "base_clk", "sys_clk";
> + bus-width = <4>;
> + cap-sd-highspeed;
> + pinctrl-names = "default";
> + pinctrl-0 = <&pinctrl_sdhc1>;
> + };
> +...
>
> --
> 2.43.0
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2025-05-08 15:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-07 6:29 [PATCH 0/2] dt-bindings: dma: microchip,sdhci-pic32: Add json schema for text binding Charan Pedumuru
2025-05-07 6:29 ` [PATCH 1/2] mips: dts: pic32: pic32mzda: Rename the sdhci nodename to match with common mmc-controller binding Charan Pedumuru
2025-05-08 15:09 ` Krzysztof Kozlowski
2025-05-20 6:50 ` Thomas Bogendoerfer
2025-05-07 6:29 ` [PATCH 2/2] dt-binding: mmc: microchip,sdhci-pic32: convert text based binding to json schema Charan Pedumuru
2025-05-08 15:04 ` Conor Dooley [this message]
2025-05-19 12:31 ` Ulf Hansson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250508-study-pursuable-05ea1564c9cd@spud \
--to=conor@kernel.org \
--cc=charan.pedumuru@gmail.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=robh@kernel.org \
--cc=tsbogend@alpha.franken.de \
--cc=ulf.hansson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox