dt-bindings: mmc: Convert TI OMAP2420 MMC to DT schema
Subsystems (2)
PATCH v2 1/1 dt-bindings: mmc: Convert TI OMAP2420 MMC to DT schema
Convert the Texas Instruments MMC host controller bindings to DT schema.
Note that the OMAP2420 driver will not work with OMAP2430 or later omaps. Please see the OMAP HSMMC driver for current OMAPs.
---
Changes in v2:
- Changed ti,hwmods type reference from string-array to string
- Updated ti,hwmods regex pattern to "^msdi([1-9]|[1-9][0-9]+)$"
--- .../bindings/mmc/ti,omap2420-mmc.yaml | 60 +++++++++++++++++++ .../devicetree/bindings/mmc/ti-omap.txt | 26 -------- 2 files changed, 60 insertions(+), 26 deletions(-) create mode 100644 Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml delete mode 100644 Documentation/devicetree/bindings/mmc/ti-omap.txt
Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml new file +60 -0
@@ -0,0 +1,60 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/mmc/ti,omap2420-mmc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Texas Instruments MMC host controller for OMAP1 and 2420 + +maintainers: + - Eduard Bostina <[email protected]> + +description: | + The MMC Host Controller on TI OMAP1 and 2420 family provides + an interface for MMC, SD, and SDIO types of memory cards. + +allOf: + - $ref: /schemas/mmc/mmc-controller.yaml# + +properties: + compatible: + const: ti,omap2420-mmc + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + ti,hwmods: + description: | + Name of the hwmod associated to the MMC controller. Must be + "msdi<n>" where n is the controller instance starting from 1. + $ref: /schemas/types.yaml#/definitions/string + pattern: "^msdi([1-9]|[1-9][0-9]+)$" + + dmas: + maxItems: 2 + + dma-names: + items: + - const: tx + - const: rx + +required: + - compatible + - reg + - interrupts + +unevaluatedProperties: false + +examples: + - | + mmc@4809c000 { + compatible = "ti,omap2420-mmc"; + ti,hwmods = "msdi1"; + reg = <0x4809c000 0x80>; + interrupts = <83>; + dmas = <&sdma 61 &sdma 62>; + dma-names = "tx", "rx"; + };
Documentation/devicetree/bindings/mmc/ti-omap.txt deleted +0 -26
@@ -1,26 +0,0 @@ -* TI MMC host controller for OMAP1 and 2420 - -The MMC Host Controller on TI OMAP1 and 2420 family provides -an interface for MMC, SD, and SDIO types of memory cards. - -This file documents differences between the core properties described -by mmc.txt and the properties used by the omap mmc driver. - -Note that this driver will not work with omap2430 or later omaps, -please see the omap hsmmc driver for the current omaps. - -Required properties: -- compatible: Must be "ti,omap2420-mmc", for OMAP2420 controllers -- ti,hwmods: For 2420, must be "msdi<n>", where n is controller - instance starting 1 - -Examples: - - msdi1: mmc@4809c000 { - compatible = "ti,omap2420-mmc"; - ti,hwmods = "msdi1"; - reg = <0x4809c000 0x80>; - interrupts = <83>; - dmas = <&sdma 61 &sdma 62>; - dma-names = "tx", "rx"; - };
Signature · 1 line
2.43.0
[email protected]
AI reviewThank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider: - [Medium] The `ti,hwmods` property was omitted from the `required` list during the conversion to YAML. --
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] The ti,hwmods property was omitted from the required list during the conversion to YAML. --
commit 2529eee822cb54c2e574fedc2f1d4933627359c5
Author: Eduard Bostina <[email protected]>
dt-bindings: mmc: Convert TI OMAP2420 MMC to DT schema
This commit converts the Texas Instruments MMC host controller bindings for OMAP1 and 2420 from a text format to DT schema.
Quoted 5 lines
Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml new file +0
-0
[ ... ]
Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml line 47
Quoted 4 lines
Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml new file +4
-0+required: + - compatible + - reg + - interrupts
[Severity: Medium]
Should ti,hwmods be included in this required properties list?
The original text binding in ti-omap.txt listed ti,hwmods under its Required properties. By omitting it here, device trees missing the property will pass validation, but could fail to probe at runtime since the legacy OMAP platform code relies on the hwmod framework for clock and power domain configuration.
Quoted 2 lines
Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml new file +2
-0+ +unevaluatedProperties: false
[ ... ]
Quoted 5 lines
Documentation/devicetree/bindings/mmc/ti-omap.txt deleted +0
-0
[ ... ]
Quoted 4 lines
Documentation/devicetree/bindings/mmc/ti-omap.txt deleted +0
-4-Required properties: -- compatible: Must be "ti,omap2420-mmc", for OMAP2420 controllers -- ti,hwmods: For 2420, must be "msdi<n>", where n is controller - instance starting 1
Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
Quoted 11 lines · Eduard Bostina
Convert the Texas Instruments MMC host controller bindings to DT schema.
Note that the OMAP2420 driver will not work with OMAP2430 or later omaps. Please see the OMAP HSMMC driver for current OMAPs.
Signed-off-by Eduard Bostina <[email protected]>---
Changes in v2:
- Changed ti,hwmods type reference from string-array to string
- Updated ti,hwmods regex pattern to "^msdi([1-9]|[1-9][0-9]+)$"
Best regards,
Krzysztof
Quoted 8 lines · Eduard Bostina
Convert the Texas Instruments MMC host controller bindings to DT schema.
Note that the OMAP2420 driver will not work with OMAP2430 or later omaps. Please see the OMAP HSMMC driver for current OMAPs.
Signed-off-by Eduard Bostina <[email protected]>
Applied for next, thanks!
Kind regards
Uffe
Quoted 112 lines
---
Changes in v2:
- Changed ti,hwmods type reference from string-array to string
- Updated ti,hwmods regex pattern to "^msdi([1-9]|[1-9][0-9]+)$"--- .../bindings/mmc/ti,omap2420-mmc.yaml | 60 +++++++++++++++++++ .../devicetree/bindings/mmc/ti-omap.txt | 26 -------- 2 files changed, 60 insertions(+), 26 deletions(-) create mode 100644 Documentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml delete mode 100644 Documentation/devicetree/bindings/mmc/ti-omap.txtDocumentation/devicetree/bindings/mmc/ti,omap2420-mmc.yaml new file +60
-0@@ -0,0 +1,60 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/mmc/ti,omap2420-mmc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Texas Instruments MMC host controller for OMAP1 and 2420 + +maintainers: + - Eduard Bostina <[email protected]> + +description: | + The MMC Host Controller on TI OMAP1 and 2420 family provides + an interface for MMC, SD, and SDIO types of memory cards. + +allOf: + - $ref: /schemas/mmc/mmc-controller.yaml# + +properties: + compatible: + const: ti,omap2420-mmc + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + ti,hwmods: + description: | + Name of the hwmod associated to the MMC controller. Must be + "msdi<n>" where n is the controller instance starting from 1. + $ref: /schemas/types.yaml#/definitions/string + pattern: "^msdi([1-9]|[1-9][0-9]+)$" + + dmas: + maxItems: 2 + + dma-names: + items: + - const: tx + - const: rx + +required: + - compatible + - reg + - interrupts + +unevaluatedProperties: false + +examples: + - | + mmc@4809c000 { + compatible = "ti,omap2420-mmc"; + ti,hwmods = "msdi1"; + reg = <0x4809c000 0x80>; + interrupts = <83>; + dmas = <&sdma 61 &sdma 62>; + dma-names = "tx", "rx"; + };Documentation/devicetree/bindings/mmc/ti-omap.txt deleted +0
-27@@ -1,26 +0,0 @@ -* TI MMC host controller for OMAP1 and 2420 - -The MMC Host Controller on TI OMAP1 and 2420 family provides -an interface for MMC, SD, and SDIO types of memory cards. - -This file documents differences between the core properties described -by mmc.txt and the properties used by the omap mmc driver. - -Note that this driver will not work with omap2430 or later omaps, -please see the omap hsmmc driver for the current omaps. - -Required properties: -- compatible: Must be "ti,omap2420-mmc", for OMAP2420 controllers -- ti,hwmods: For 2420, must be "msdi<n>", where n is controller - instance starting 1 - -Examples: - - msdi1: mmc@4809c000 { - compatible = "ti,omap2420-mmc"; - ti,hwmods = "msdi1"; - reg = <0x4809c000 0x80>; - interrupts = <83>; - dmas = <&sdma 61 &sdma 62>; - dma-names = "tx", "rx"; - }; --2.43.0