Skip to content

Commit e245c72

Browse files
Yttrium-32vinodkoul
authored andcommitted
dt-bindings: phy: rockchip-emmc-phy: Convert to dtschema
Convert txt bindings of Rockchip EMMC PHY to dtschema to allow for validation. Signed-off-by: Shresth Prasad <[email protected]> Reviewed-by: Krzysztof Kozlowski <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Vinod Koul <[email protected]>
1 parent 3d83abc commit e245c72

File tree

3 files changed

+77
-46
lines changed

3 files changed

+77
-46
lines changed
Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
# SPDX-License-Identifier: GPL-2.0-only
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/phy/rockchip,rk3399-emmc-phy.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Rockchip EMMC PHY
8+
9+
maintainers:
10+
- Heiko Stuebner <[email protected]>
11+
12+
properties:
13+
compatible:
14+
const: rockchip,rk3399-emmc-phy
15+
16+
reg:
17+
maxItems: 1
18+
19+
clocks:
20+
maxItems: 1
21+
22+
clock-names:
23+
const: emmcclk
24+
25+
drive-impedance-ohm:
26+
$ref: /schemas/types.yaml#/definitions/uint32
27+
description:
28+
Specifies the drive impedance in Ohm.
29+
enum: [33, 40, 50, 66, 100]
30+
default: 50
31+
32+
rockchip,enable-strobe-pulldown:
33+
type: boolean
34+
description: |
35+
Enable internal pull-down for the strobe
36+
line. If not set, pull-down is not used.
37+
38+
rockchip,output-tapdelay-select:
39+
$ref: /schemas/types.yaml#/definitions/uint32
40+
description:
41+
Specifies the phyctrl_otapdlysec register.
42+
default: 0x4
43+
maximum: 0xf
44+
45+
"#phy-cells":
46+
const: 0
47+
48+
required:
49+
- compatible
50+
- reg
51+
- "#phy-cells"
52+
53+
additionalProperties: false
54+
55+
examples:
56+
- |
57+
phy@f780 {
58+
compatible = "rockchip,rk3399-emmc-phy";
59+
reg = <0xf780 0x20>;
60+
clocks = <&sdhci>;
61+
clock-names = "emmcclk";
62+
drive-impedance-ohm = <50>;
63+
#phy-cells = <0>;
64+
};

Documentation/devicetree/bindings/phy/rockchip-emmc-phy.txt

Lines changed: 0 additions & 43 deletions
This file was deleted.

Documentation/devicetree/bindings/soc/rockchip/grf.yaml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -176,9 +176,10 @@ allOf:
176176
Documentation/devicetree/bindings/phy/rockchip-pcie-phy.txt
177177

178178
patternProperties:
179-
"phy@[0-9a-f]+$":
180-
description:
181-
Documentation/devicetree/bindings/phy/rockchip-emmc-phy.txt
179+
"^phy@[0-9a-f]+$":
180+
type: object
181+
$ref: /schemas/phy/rockchip,rk3399-emmc-phy.yaml#
182+
unevaluatedProperties: false
182183

183184
- if:
184185
properties:
@@ -292,6 +293,15 @@ examples:
292293
#phy-cells = <0>;
293294
};
294295
296+
phy@f780 {
297+
compatible = "rockchip,rk3399-emmc-phy";
298+
reg = <0xf780 0x20>;
299+
clocks = <&sdhci>;
300+
clock-names = "emmcclk";
301+
drive-impedance-ohm = <50>;
302+
#phy-cells = <0>;
303+
};
304+
295305
u2phy0: usb2phy@e450 {
296306
compatible = "rockchip,rk3399-usb2phy";
297307
reg = <0xe450 0x10>;

0 commit comments

Comments
 (0)