Tom Rini | 53633a8 | 2024-02-29 12:33:36 -0500 | [diff] [blame] | 1 | # SPDX-License-Identifier: GPL-2.0 |
| 2 | %YAML 1.2 |
| 3 | --- |
| 4 | $id: http://devicetree.org/schemas/display/allwinner,sun6i-a31-mipi-dsi.yaml# |
| 5 | $schema: http://devicetree.org/meta-schemas/core.yaml# |
| 6 | |
| 7 | title: Allwinner A31 MIPI-DSI Controller |
| 8 | |
| 9 | maintainers: |
| 10 | - Chen-Yu Tsai <wens@csie.org> |
| 11 | - Maxime Ripard <mripard@kernel.org> |
| 12 | |
| 13 | properties: |
| 14 | compatible: |
| 15 | oneOf: |
| 16 | - enum: |
| 17 | - allwinner,sun6i-a31-mipi-dsi |
| 18 | - allwinner,sun50i-a64-mipi-dsi |
| 19 | - allwinner,sun50i-a100-mipi-dsi |
| 20 | - items: |
| 21 | - const: allwinner,sun20i-d1-mipi-dsi |
| 22 | - const: allwinner,sun50i-a100-mipi-dsi |
| 23 | |
| 24 | reg: |
| 25 | maxItems: 1 |
| 26 | |
| 27 | interrupts: |
| 28 | maxItems: 1 |
| 29 | |
| 30 | clocks: |
| 31 | minItems: 1 |
| 32 | items: |
| 33 | - description: Bus Clock |
| 34 | - description: Module Clock |
| 35 | |
| 36 | clock-names: |
| 37 | items: |
| 38 | - const: bus |
| 39 | - const: mod |
| 40 | |
| 41 | resets: |
| 42 | maxItems: 1 |
| 43 | |
| 44 | vcc-dsi-supply: |
| 45 | description: VCC-DSI power supply of the DSI encoder |
| 46 | |
| 47 | phys: |
| 48 | maxItems: 1 |
| 49 | |
| 50 | phy-names: |
| 51 | const: dphy |
| 52 | |
| 53 | port: |
| 54 | $ref: /schemas/graph.yaml#/properties/port |
| 55 | description: |
| 56 | The port should be the input endpoint, usually coming from the |
| 57 | associated TCON. |
| 58 | |
| 59 | required: |
| 60 | - compatible |
| 61 | - reg |
| 62 | - interrupts |
| 63 | - clocks |
| 64 | - phys |
| 65 | - phy-names |
| 66 | - resets |
| 67 | - port |
| 68 | |
| 69 | allOf: |
| 70 | - $ref: dsi-controller.yaml# |
| 71 | - if: |
| 72 | properties: |
| 73 | compatible: |
| 74 | contains: |
| 75 | enum: |
| 76 | - allwinner,sun6i-a31-mipi-dsi |
| 77 | - allwinner,sun50i-a100-mipi-dsi |
| 78 | |
| 79 | then: |
| 80 | properties: |
| 81 | clocks: |
| 82 | minItems: 2 |
| 83 | |
| 84 | required: |
| 85 | - clock-names |
| 86 | |
| 87 | else: |
| 88 | properties: |
| 89 | clocks: |
| 90 | maxItems: 1 |
| 91 | |
| 92 | - if: |
| 93 | properties: |
| 94 | compatible: |
| 95 | contains: |
| 96 | enum: |
| 97 | - allwinner,sun6i-a31-mipi-dsi |
| 98 | - allwinner,sun50i-a64-mipi-dsi |
| 99 | |
| 100 | then: |
| 101 | required: |
| 102 | - vcc-dsi-supply |
| 103 | |
| 104 | unevaluatedProperties: false |
| 105 | |
| 106 | examples: |
| 107 | - | |
| 108 | dsi0: dsi@1ca0000 { |
| 109 | compatible = "allwinner,sun6i-a31-mipi-dsi"; |
| 110 | reg = <0x01ca0000 0x1000>; |
| 111 | interrupts = <0 89 4>; |
| 112 | clocks = <&ccu 23>, <&ccu 96>; |
| 113 | clock-names = "bus", "mod"; |
| 114 | resets = <&ccu 4>; |
| 115 | phys = <&dphy0>; |
| 116 | phy-names = "dphy"; |
| 117 | vcc-dsi-supply = <®_dcdc1>; |
| 118 | #address-cells = <1>; |
| 119 | #size-cells = <0>; |
| 120 | |
| 121 | panel@0 { |
| 122 | compatible = "bananapi,lhr050h41", "ilitek,ili9881c"; |
| 123 | reg = <0>; |
| 124 | power-supply = <®_display>; |
| 125 | reset-gpios = <&r_pio 0 5 1>; /* PL05 */ |
| 126 | backlight = <&pwm_bl>; |
| 127 | }; |
| 128 | |
| 129 | port { |
| 130 | dsi0_in_tcon0: endpoint { |
| 131 | remote-endpoint = <&tcon0_out_dsi0>; |
| 132 | }; |
| 133 | }; |
| 134 | }; |
| 135 | |
| 136 | ... |