Sergei Shtylyov | 5f45cec | 2016-08-26 23:21:42 +0300 | [diff] [blame] | 1 | /* |
| 2 | * Device Tree Source for the Wheat board |
| 3 | * |
| 4 | * Copyright (C) 2016 Renesas Electronics Corporation |
| 5 | * Copyright (C) 2016 Cogent Embedded, Inc. |
| 6 | * |
| 7 | * This file is licensed under the terms of the GNU General Public License |
| 8 | * version 2. This program is licensed "as is" without any warranty of any |
| 9 | * kind, whether express or implied. |
| 10 | */ |
| 11 | |
| 12 | /dts-v1/; |
| 13 | #include "r8a7792.dtsi" |
Sergei Shtylyov | 0c157ad | 2016-08-31 01:24:41 +0300 | [diff] [blame] | 14 | #include <dt-bindings/gpio/gpio.h> |
Sergei Shtylyov | fa8f4ab | 2016-09-06 00:33:05 +0300 | [diff] [blame] | 15 | #include <dt-bindings/input/input.h> |
Sergei Shtylyov | 5f45cec | 2016-08-26 23:21:42 +0300 | [diff] [blame] | 16 | |
| 17 | / { |
| 18 | model = "Wheat"; |
| 19 | compatible = "renesas,wheat", "renesas,r8a7792"; |
| 20 | |
| 21 | aliases { |
| 22 | serial0 = &scif0; |
| 23 | }; |
| 24 | |
| 25 | chosen { |
Sergei Shtylyov | 1d9a17d | 2016-08-26 23:23:13 +0300 | [diff] [blame] | 26 | bootargs = "ignore_loglevel rw root=/dev/nfs ip=dhcp"; |
Sergei Shtylyov | 5f45cec | 2016-08-26 23:21:42 +0300 | [diff] [blame] | 27 | stdout-path = "serial0:115200n8"; |
| 28 | }; |
| 29 | |
| 30 | memory@40000000 { |
| 31 | device_type = "memory"; |
| 32 | reg = <0 0x40000000 0 0x40000000>; |
| 33 | }; |
Sergei Shtylyov | 1d9a17d | 2016-08-26 23:23:13 +0300 | [diff] [blame] | 34 | |
| 35 | d3_3v: regulator-3v3 { |
| 36 | compatible = "regulator-fixed"; |
| 37 | regulator-name = "D3.3V"; |
| 38 | regulator-min-microvolt = <3300000>; |
| 39 | regulator-max-microvolt = <3300000>; |
| 40 | regulator-boot-on; |
| 41 | regulator-always-on; |
| 42 | }; |
| 43 | |
| 44 | ethernet@18000000 { |
| 45 | compatible = "smsc,lan89218", "smsc,lan9115"; |
| 46 | reg = <0 0x18000000 0 0x100>; |
| 47 | phy-mode = "mii"; |
| 48 | interrupt-parent = <&irqc>; |
| 49 | interrupts = <0 IRQ_TYPE_EDGE_FALLING>; |
| 50 | smsc,irq-push-pull; |
| 51 | smsc,save-mac-address; |
| 52 | reg-io-width = <4>; |
| 53 | vddvario-supply = <&d3_3v>; |
| 54 | vdd33a-supply = <&d3_3v>; |
| 55 | |
| 56 | pinctrl-0 = <&lan89218_pins>; |
| 57 | pinctrl-names = "default"; |
| 58 | }; |
Sergei Shtylyov | 0c157ad | 2016-08-31 01:24:41 +0300 | [diff] [blame] | 59 | |
Sergei Shtylyov | fa8f4ab | 2016-09-06 00:33:05 +0300 | [diff] [blame] | 60 | keyboard { |
| 61 | compatible = "gpio-keys"; |
| 62 | |
| 63 | key-a { |
| 64 | linux,code = <KEY_A>; |
| 65 | label = "SW2"; |
| 66 | wakeup-source; |
| 67 | debounce-interval = <20>; |
| 68 | gpios = <&gpio3 20 GPIO_ACTIVE_LOW>; |
| 69 | }; |
| 70 | key-b { |
| 71 | linux,code = <KEY_B>; |
| 72 | label = "SW3"; |
| 73 | wakeup-source; |
| 74 | debounce-interval = <20>; |
| 75 | gpios = <&gpio11 2 GPIO_ACTIVE_LOW>; |
| 76 | }; |
| 77 | }; |
| 78 | |
Sergei Shtylyov | 0c157ad | 2016-08-31 01:24:41 +0300 | [diff] [blame] | 79 | vcc_sdhi0: regulator-vcc-sdhi0 { |
| 80 | compatible = "regulator-fixed"; |
| 81 | |
| 82 | regulator-name = "SDHI0 Vcc"; |
| 83 | regulator-min-microvolt = <3300000>; |
| 84 | regulator-max-microvolt = <3300000>; |
| 85 | |
| 86 | gpio = <&gpio11 12 GPIO_ACTIVE_HIGH>; |
| 87 | enable-active-high; |
| 88 | }; |
Sergei Shtylyov | f6eea82 | 2016-09-23 00:06:43 +0300 | [diff] [blame] | 89 | |
| 90 | hdmi-out0 { |
| 91 | compatible = "hdmi-connector"; |
| 92 | type = "a"; |
| 93 | |
| 94 | port { |
| 95 | hdmi_con0: endpoint { |
| 96 | remote-endpoint = <&adv7513_0_out>; |
| 97 | }; |
| 98 | }; |
| 99 | }; |
| 100 | |
| 101 | hdmi-out1 { |
| 102 | compatible = "hdmi-connector"; |
| 103 | type = "a"; |
| 104 | |
| 105 | port { |
| 106 | hdmi_con1: endpoint { |
| 107 | remote-endpoint = <&adv7513_1_out>; |
| 108 | }; |
| 109 | }; |
| 110 | }; |
| 111 | |
| 112 | osc2_clk: osc2 { |
| 113 | compatible = "fixed-clock"; |
| 114 | #clock-cells = <0>; |
| 115 | clock-frequency = <74250000>; |
| 116 | }; |
Sergei Shtylyov | 5f45cec | 2016-08-26 23:21:42 +0300 | [diff] [blame] | 117 | }; |
| 118 | |
| 119 | &extal_clk { |
| 120 | clock-frequency = <20000000>; |
| 121 | }; |
| 122 | |
| 123 | &pfc { |
| 124 | scif0_pins: scif0 { |
| 125 | groups = "scif0_data"; |
| 126 | function = "scif0"; |
| 127 | }; |
Sergei Shtylyov | 1d9a17d | 2016-08-26 23:23:13 +0300 | [diff] [blame] | 128 | |
| 129 | lan89218_pins: lan89218 { |
| 130 | intc { |
| 131 | groups = "intc_irq0"; |
| 132 | function = "intc"; |
| 133 | }; |
| 134 | lbsc { |
| 135 | groups = "lbsc_ex_cs0"; |
| 136 | function = "lbsc"; |
| 137 | }; |
| 138 | }; |
Sergei Shtylyov | 4ea71e6 | 2016-08-29 23:11:26 +0300 | [diff] [blame] | 139 | |
| 140 | can0_pins: can0 { |
| 141 | groups = "can0_data"; |
| 142 | function = "can0"; |
| 143 | }; |
| 144 | |
| 145 | can1_pins: can1 { |
| 146 | groups = "can1_data"; |
| 147 | function = "can1"; |
| 148 | }; |
Sergei Shtylyov | 0c157ad | 2016-08-31 01:24:41 +0300 | [diff] [blame] | 149 | |
| 150 | sdhi0_pins: sdhi0 { |
| 151 | groups = "sdhi0_data4", "sdhi0_ctrl"; |
| 152 | function = "sdhi0"; |
| 153 | }; |
Sergei Shtylyov | e678114 | 2016-09-03 01:09:26 +0300 | [diff] [blame] | 154 | |
| 155 | qspi_pins: qspi { |
| 156 | groups = "qspi_ctrl", "qspi_data4"; |
| 157 | function = "qspi"; |
| 158 | }; |
Sergei Shtylyov | f6eea82 | 2016-09-23 00:06:43 +0300 | [diff] [blame] | 159 | |
| 160 | du0_pins: du0 { |
| 161 | groups = "du0_rgb888", "du0_sync", "du0_disp"; |
| 162 | function = "du0"; |
| 163 | }; |
| 164 | |
| 165 | du1_pins: du1 { |
| 166 | groups = "du1_rgb666", "du1_sync", "du1_disp"; |
| 167 | function = "du1"; |
| 168 | }; |
Sergei Shtylyov | 5f45cec | 2016-08-26 23:21:42 +0300 | [diff] [blame] | 169 | }; |
| 170 | |
| 171 | &scif0 { |
| 172 | pinctrl-0 = <&scif0_pins>; |
| 173 | pinctrl-names = "default"; |
| 174 | |
| 175 | status = "okay"; |
| 176 | }; |
Sergei Shtylyov | 4ea71e6 | 2016-08-29 23:11:26 +0300 | [diff] [blame] | 177 | |
| 178 | &can0 { |
| 179 | pinctrl-0 = <&can0_pins>; |
| 180 | pinctrl-names = "default"; |
| 181 | |
| 182 | status = "okay"; |
| 183 | }; |
| 184 | |
| 185 | &can1 { |
| 186 | pinctrl-0 = <&can1_pins>; |
| 187 | pinctrl-names = "default"; |
| 188 | |
| 189 | status = "okay"; |
| 190 | }; |
Sergei Shtylyov | 0c157ad | 2016-08-31 01:24:41 +0300 | [diff] [blame] | 191 | |
| 192 | &sdhi0 { |
| 193 | pinctrl-0 = <&sdhi0_pins>; |
| 194 | pinctrl-names = "default"; |
| 195 | |
| 196 | vmmc-supply = <&vcc_sdhi0>; |
| 197 | cd-gpios = <&gpio11 11 GPIO_ACTIVE_LOW>; |
| 198 | status = "okay"; |
| 199 | }; |
Sergei Shtylyov | e678114 | 2016-09-03 01:09:26 +0300 | [diff] [blame] | 200 | |
| 201 | &qspi { |
| 202 | pinctrl-0 = <&qspi_pins>; |
| 203 | pinctrl-names = "default"; |
| 204 | status = "okay"; |
| 205 | |
| 206 | flash@0 { |
| 207 | compatible = "spansion,s25fl512s", "jedec,spi-nor"; |
| 208 | reg = <0>; |
| 209 | spi-max-frequency = <30000000>; |
| 210 | spi-tx-bus-width = <4>; |
| 211 | spi-rx-bus-width = <4>; |
| 212 | spi-cpol; |
| 213 | spi-cpha; |
| 214 | m25p,fast-read; |
| 215 | |
| 216 | partitions { |
| 217 | compatible = "fixed-partitions"; |
| 218 | #address-cells = <1>; |
| 219 | #size-cells = <1>; |
| 220 | |
| 221 | partition@0 { |
| 222 | label = "loader"; |
| 223 | reg = <0x00000000 0x00040000>; |
| 224 | read-only; |
| 225 | }; |
| 226 | partition@40000 { |
| 227 | label = "user"; |
| 228 | reg = <0x00040000 0x00400000>; |
| 229 | read-only; |
| 230 | }; |
| 231 | partition@440000 { |
| 232 | label = "flash"; |
| 233 | reg = <0x00440000 0x03bc0000>; |
| 234 | }; |
| 235 | }; |
| 236 | }; |
| 237 | }; |
Sergei Shtylyov | f6eea82 | 2016-09-23 00:06:43 +0300 | [diff] [blame] | 238 | |
| 239 | &i2c4 { |
| 240 | status = "okay"; |
| 241 | clock-frequency = <400000>; |
| 242 | |
| 243 | hdmi@3d { |
| 244 | compatible = "adi,adv7513"; |
| 245 | reg = <0x3d>; |
| 246 | |
| 247 | adi,input-depth = <8>; |
| 248 | adi,input-colorspace = "rgb"; |
| 249 | adi,input-clock = "1x"; |
| 250 | adi,input-style = <1>; |
| 251 | adi,input-justification = "evenly"; |
| 252 | |
| 253 | ports { |
| 254 | #address-cells = <1>; |
| 255 | #size-cells = <0>; |
| 256 | |
| 257 | port@0 { |
| 258 | reg = <0>; |
| 259 | adv7513_0_in: endpoint { |
| 260 | remote-endpoint = <&du_out_rgb0>; |
| 261 | }; |
| 262 | }; |
| 263 | |
| 264 | port@1 { |
| 265 | reg = <1>; |
| 266 | adv7513_0_out: endpoint { |
| 267 | remote-endpoint = <&hdmi_con0>; |
| 268 | }; |
| 269 | }; |
| 270 | }; |
| 271 | }; |
| 272 | |
| 273 | hdmi@39 { |
| 274 | compatible = "adi,adv7513"; |
| 275 | reg = <0x39>; |
| 276 | |
| 277 | adi,input-depth = <8>; |
| 278 | adi,input-colorspace = "rgb"; |
| 279 | adi,input-clock = "1x"; |
| 280 | adi,input-style = <1>; |
| 281 | adi,input-justification = "evenly"; |
| 282 | |
| 283 | ports { |
| 284 | #address-cells = <1>; |
| 285 | #size-cells = <0>; |
| 286 | |
| 287 | port@0 { |
| 288 | reg = <0>; |
| 289 | adv7513_1_in: endpoint { |
| 290 | remote-endpoint = <&du_out_rgb1>; |
| 291 | }; |
| 292 | }; |
| 293 | |
| 294 | port@1 { |
| 295 | reg = <1>; |
| 296 | adv7513_1_out: endpoint { |
| 297 | remote-endpoint = <&hdmi_con1>; |
| 298 | }; |
| 299 | }; |
| 300 | }; |
| 301 | }; |
| 302 | }; |
| 303 | |
| 304 | &du { |
| 305 | pinctrl-0 = <&du0_pins &du1_pins>; |
| 306 | pinctrl-names = "default"; |
| 307 | |
| 308 | clocks = <&mstp7_clks R8A7792_CLK_DU0>, <&mstp7_clks R8A7792_CLK_DU1>, |
| 309 | <&osc2_clk>; |
| 310 | clock-names = "du.0", "du.1", "dclkin.0"; |
| 311 | status = "okay"; |
| 312 | |
| 313 | ports { |
| 314 | port@0 { |
| 315 | endpoint { |
| 316 | remote-endpoint = <&adv7513_0_in>; |
| 317 | }; |
| 318 | }; |
| 319 | port@1 { |
| 320 | endpoint { |
| 321 | remote-endpoint = <&adv7513_1_in>; |
| 322 | }; |
| 323 | }; |
| 324 | }; |
| 325 | }; |