1// SPDX-License-Identifier: GPL-2.0-or-later 2/* 3 * Copyright 2012 Free Electrons 4 */ 5 6/* 7 * The CFA-10049 is an expansion board for the CFA-10036 module, thus we 8 * need to include the CFA-10036 DTS. 9 */ 10#include "imx28-cfa10036.dts" 11 12/ { 13 model = "Crystalfontz CFA-10049 Board"; 14 compatible = "crystalfontz,cfa10049", "crystalfontz,cfa10036", "fsl,imx28"; 15 16 i2cmux { 17 compatible = "i2c-mux-gpio"; 18 #address-cells = <1>; 19 #size-cells = <0>; 20 pinctrl-names = "default"; 21 pinctrl-0 = <&i2cmux_pins_cfa10049>; 22 mux-gpios = <&gpio1 22 0 &gpio1 23 0>; 23 i2c-parent = <&i2c1>; 24 25 i2c@0 { 26 #address-cells = <1>; 27 #size-cells = <0>; 28 reg = <0>; 29 30 adc0: nau7802@2a { 31 compatible = "nuvoton,nau7802"; 32 reg = <0x2a>; 33 nuvoton,vldo = <3000>; 34 }; 35 }; 36 37 i2c@1 { 38 #address-cells = <1>; 39 #size-cells = <0>; 40 reg = <1>; 41 42 adc1: nau7802@2a { 43 compatible = "nuvoton,nau7802"; 44 reg = <0x2a>; 45 nuvoton,vldo = <3000>; 46 }; 47 }; 48 49 i2c@2 { 50 #address-cells = <1>; 51 #size-cells = <0>; 52 reg = <2>; 53 54 adc2: nau7802@2a { 55 compatible = "nuvoton,nau7802"; 56 reg = <0x2a>; 57 nuvoton,vldo = <3000>; 58 }; 59 }; 60 61 i2c@3 { 62 reg = <3>; 63 #address-cells = <1>; 64 #size-cells = <0>; 65 66 pca9555: pca9555@20 { 67 compatible = "nxp,pca9555"; 68 pinctrl-names = "default"; 69 pinctrl-0 = <&pca_pins_cfa10049>; 70 interrupt-parent = <&gpio2>; 71 interrupts = <19 0x2>; 72 gpio-controller; 73 #gpio-cells = <2>; 74 interrupt-controller; 75 #interrupt-cells = <2>; 76 reg = <0x20>; 77 }; 78 }; 79 }; 80 81 reg_usb1_vbus: regulator-0 { 82 compatible = "regulator-fixed"; 83 pinctrl-names = "default"; 84 pinctrl-0 = <&usb_pins_cfa10049>; 85 regulator-name = "usb1_vbus"; 86 regulator-min-microvolt = <5000000>; 87 regulator-max-microvolt = <5000000>; 88 gpio = <&gpio0 7 1>; 89 }; 90 91 spi-2 { 92 compatible = "spi-gpio"; 93 pinctrl-names = "default"; 94 pinctrl-0 = <&spi2_pins_cfa10049>; 95 status = "okay"; 96 sck-gpios = <&gpio2 16 0>; 97 mosi-gpios = <&gpio2 17 0>; 98 miso-gpios = <&gpio2 18 0>; 99 cs-gpios = <&gpio3 5 0>; 100 num-chipselects = <1>; 101 #address-cells = <1>; 102 #size-cells = <0>; 103 104 hx8357: hx8357@0 { 105 compatible = "himax,hx8357b", "himax,hx8357"; 106 reg = <0>; 107 spi-max-frequency = <100000>; 108 spi-cpol; 109 spi-cpha; 110 gpios-reset = <&gpio3 30 0>; 111 im-gpios = <&gpio5 4 0 &gpio5 5 0 &gpio5 6 0>; 112 }; 113 }; 114 115 spi-3 { 116 compatible = "spi-gpio"; 117 pinctrl-names = "default"; 118 pinctrl-0 = <&spi3_pins_cfa10049>; 119 status = "okay"; 120 sck-gpios = <&gpio0 24 0>; 121 mosi-gpios = <&gpio0 28 0>; 122 cs-gpios = <&gpio0 17 0 &gpio0 26 0 &gpio0 27 0>; 123 num-chipselects = <3>; 124 #address-cells = <1>; 125 #size-cells = <0>; 126 127 gpio5: gpio5@0 { 128 compatible = "fairchild,74hc595"; 129 gpio-controller; 130 #gpio-cells = <2>; 131 reg = <0>; 132 registers-number = <2>; 133 spi-max-frequency = <100000>; 134 }; 135 136 gpio6: gpio6@1 { 137 compatible = "fairchild,74hc595"; 138 gpio-controller; 139 #gpio-cells = <2>; 140 reg = <1>; 141 registers-number = <4>; 142 spi-max-frequency = <100000>; 143 }; 144 145 dac0: dh2228@2 { 146 compatible = "rohm,dh2228fv"; 147 reg = <2>; 148 spi-max-frequency = <100000>; 149 }; 150 }; 151 152 gpio-keys { 153 compatible = "gpio-keys"; 154 pinctrl-names = "default"; 155 pinctrl-0 = <&rotary_btn_pins_cfa10049>; 156 157 rotary-button { 158 label = "rotary_button"; 159 gpios = <&gpio3 26 1>; 160 debounce-interval = <10>; 161 linux,code = <28>; 162 }; 163 }; 164 165 rotary { 166 compatible = "rotary-encoder"; 167 pinctrl-names = "default"; 168 pinctrl-0 = <&rotary_pins_cfa10049>; 169 gpios = <&gpio3 24 1>, <&gpio3 25 1>; 170 linux,axis = <1>; /* REL_Y */ 171 rotary-encoder,relative-axis; 172 }; 173 174 backlight { 175 compatible = "pwm-backlight"; 176 pwms = <&pwm 3 5000000>; 177 brightness-levels = <0 4 8 16 32 64 128 255>; 178 default-brightness-level = <6>; 179 180 }; 181 182 onewire { 183 compatible = "w1-gpio"; 184 pinctrl-names = "default"; 185 pinctrl-0 = <&w1_gpio_pins>; 186 status = "okay"; 187 gpios = <&gpio1 21 0>; 188 }; 189}; 190 191&i2c1 { 192 pinctrl-names = "default"; 193 pinctrl-0 = <&i2c1_pins_a>; 194 status = "okay"; 195}; 196 197&lcdif { 198 pinctrl-names = "default"; 199 pinctrl-0 = <&lcdif_18bit_pins_cfa10049 200 &lcdif_pins_cfa10049 201 &lcdif_pins_cfa10049_pullup>; 202 display = <&display0>; 203 status = "okay"; 204 205 display0: display0 { 206 bits-per-pixel = <32>; 207 bus-width = <18>; 208 209 display-timings { 210 native-mode = <&timing0>; 211 timing0: timing0 { 212 clock-frequency = <9216000>; 213 hactive = <320>; 214 vactive = <480>; 215 hback-porch = <2>; 216 hfront-porch = <2>; 217 vback-porch = <2>; 218 vfront-porch = <2>; 219 hsync-len = <15>; 220 vsync-len = <15>; 221 hsync-active = <0>; 222 vsync-active = <0>; 223 de-active = <1>; 224 pixelclk-active = <1>; 225 }; 226 }; 227 }; 228}; 229 230&lradc { 231 fsl,lradc-touchscreen-wires = <4>; 232 status = "okay"; 233}; 234 235&mac0 { 236 phy-mode = "rmii"; 237 pinctrl-names = "default"; 238 pinctrl-0 = <&mac0_pins_a 239 &mac0_pins_cfa10049>; 240 phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>; 241 phy-reset-duration = <100>; 242 status = "okay"; 243}; 244 245&pinctrl { 246 usb_pins_cfa10049: usb-10049@0 { 247 reg = <0>; 248 fsl,pinmux-ids = < 249 MX28_PAD_GPMI_D07__GPIO_0_7 250 >; 251 fsl,drive-strength = <MXS_DRIVE_4mA>; 252 fsl,voltage = <MXS_VOLTAGE_HIGH>; 253 fsl,pull-up = <MXS_PULL_DISABLE>; 254 }; 255 256 i2cmux_pins_cfa10049: i2cmux-10049@0 { 257 reg = <0>; 258 fsl,pinmux-ids = < 259 MX28_PAD_LCD_D22__GPIO_1_22 260 MX28_PAD_LCD_D23__GPIO_1_23 261 >; 262 fsl,drive-strength = <MXS_DRIVE_4mA>; 263 fsl,voltage = <MXS_VOLTAGE_HIGH>; 264 fsl,pull-up = <MXS_PULL_DISABLE>; 265 }; 266 267 mac0_pins_cfa10049: mac0-10049@0 { 268 reg = <0>; 269 fsl,pinmux-ids = < 270 MX28_PAD_SSP2_SS2__GPIO_2_21 271 >; 272 fsl,drive-strength = <MXS_DRIVE_4mA>; 273 fsl,voltage = <MXS_VOLTAGE_HIGH>; 274 fsl,pull-up = <MXS_PULL_DISABLE>; 275 }; 276 277 pca_pins_cfa10049: pca-10049@0 { 278 reg = <0>; 279 fsl,pinmux-ids = < 280 MX28_PAD_SSP2_SS0__GPIO_2_19 281 >; 282 fsl,drive-strength = <MXS_DRIVE_4mA>; 283 fsl,voltage = <MXS_VOLTAGE_HIGH>; 284 fsl,pull-up = <MXS_PULL_ENABLE>; 285 }; 286 287 rotary_pins_cfa10049: rotary-10049@0 { 288 reg = <0>; 289 fsl,pinmux-ids = < 290 MX28_PAD_I2C0_SCL__GPIO_3_24 291 MX28_PAD_I2C0_SDA__GPIO_3_25 292 >; 293 fsl,drive-strength = <MXS_DRIVE_4mA>; 294 fsl,voltage = <MXS_VOLTAGE_HIGH>; 295 fsl,pull-up = <MXS_PULL_ENABLE>; 296 }; 297 298 rotary_btn_pins_cfa10049: rotary-btn-10049@0 { 299 reg = <0>; 300 fsl,pinmux-ids = < 301 MX28_PAD_SAIF1_SDATA0__GPIO_3_26 302 >; 303 fsl,drive-strength = <MXS_DRIVE_4mA>; 304 fsl,voltage = <MXS_VOLTAGE_HIGH>; 305 fsl,pull-up = <MXS_PULL_ENABLE>; 306 }; 307 308 spi2_pins_cfa10049: spi2-cfa10049@0 { 309 reg = <0>; 310 fsl,pinmux-ids = < 311 MX28_PAD_SSP2_SCK__GPIO_2_16 312 MX28_PAD_SSP2_MOSI__GPIO_2_17 313 MX28_PAD_SSP2_MISO__GPIO_2_18 314 MX28_PAD_AUART1_TX__GPIO_3_5 315 >; 316 fsl,drive-strength = <MXS_DRIVE_8mA>; 317 fsl,voltage = <MXS_VOLTAGE_HIGH>; 318 fsl,pull-up = <MXS_PULL_ENABLE>; 319 }; 320 321 spi3_pins_cfa10049: spi3-cfa10049@0 { 322 reg = <0>; 323 fsl,pinmux-ids = < 324 MX28_PAD_GPMI_RDN__GPIO_0_24 325 MX28_PAD_GPMI_RESETN__GPIO_0_28 326 MX28_PAD_GPMI_CE1N__GPIO_0_17 327 MX28_PAD_GPMI_ALE__GPIO_0_26 328 MX28_PAD_GPMI_CLE__GPIO_0_27 329 >; 330 fsl,drive-strength = <MXS_DRIVE_8mA>; 331 fsl,voltage = <MXS_VOLTAGE_HIGH>; 332 fsl,pull-up = <MXS_PULL_ENABLE>; 333 }; 334 335 lcdif_18bit_pins_cfa10049: lcdif-18bit@0 { 336 reg = <0>; 337 fsl,pinmux-ids = < 338 MX28_PAD_LCD_D00__LCD_D0 339 MX28_PAD_LCD_D01__LCD_D1 340 MX28_PAD_LCD_D02__LCD_D2 341 MX28_PAD_LCD_D03__LCD_D3 342 MX28_PAD_LCD_D04__LCD_D4 343 MX28_PAD_LCD_D05__LCD_D5 344 MX28_PAD_LCD_D06__LCD_D6 345 MX28_PAD_LCD_D07__LCD_D7 346 MX28_PAD_LCD_D08__LCD_D8 347 MX28_PAD_LCD_D09__LCD_D9 348 MX28_PAD_LCD_D10__LCD_D10 349 MX28_PAD_LCD_D11__LCD_D11 350 MX28_PAD_LCD_D12__LCD_D12 351 MX28_PAD_LCD_D13__LCD_D13 352 MX28_PAD_LCD_D14__LCD_D14 353 MX28_PAD_LCD_D15__LCD_D15 354 MX28_PAD_LCD_D16__LCD_D16 355 MX28_PAD_LCD_D17__LCD_D17 356 >; 357 fsl,drive-strength = <MXS_DRIVE_4mA>; 358 fsl,voltage = <MXS_VOLTAGE_HIGH>; 359 fsl,pull-up = <MXS_PULL_DISABLE>; 360 }; 361 362 lcdif_pins_cfa10049: lcdif-evk@0 { 363 reg = <0>; 364 fsl,pinmux-ids = < 365 MX28_PAD_LCD_RD_E__LCD_VSYNC 366 MX28_PAD_LCD_WR_RWN__LCD_HSYNC 367 MX28_PAD_LCD_RS__LCD_DOTCLK 368 MX28_PAD_LCD_CS__LCD_ENABLE 369 >; 370 fsl,drive-strength = <MXS_DRIVE_4mA>; 371 fsl,voltage = <MXS_VOLTAGE_HIGH>; 372 fsl,pull-up = <MXS_PULL_DISABLE>; 373 }; 374 375 lcdif_pins_cfa10049_pullup: lcdif-10049-pullup@0 { 376 reg = <0>; 377 fsl,pinmux-ids = < 378 MX28_PAD_LCD_RESET__GPIO_3_30 379 >; 380 fsl,drive-strength = <MXS_DRIVE_4mA>; 381 fsl,voltage = <MXS_VOLTAGE_HIGH>; 382 fsl,pull-up = <MXS_PULL_ENABLE>; 383 }; 384 385 w1_gpio_pins: w1-gpio@0 { 386 reg = <0>; 387 fsl,pinmux-ids = < 388 MX28_PAD_LCD_D21__GPIO_1_21 389 >; 390 fsl,drive-strength = <MXS_DRIVE_8mA>; 391 fsl,voltage = <MXS_VOLTAGE_HIGH>; 392 fsl,pull-up = <MXS_PULL_DISABLE>; /* 0 will enable the keeper */ 393 }; 394}; 395 396&pwm { 397 pinctrl-names = "default"; 398 pinctrl-0 = <&pwm3_pins_b>; 399 status = "okay"; 400}; 401 402&usb1 { 403 vbus-supply = <®_usb1_vbus>; 404 pinctrl-0 = <&usb1_pins_a>; 405 pinctrl-names = "default"; 406 status = "okay"; 407}; 408 409&usbphy1 { 410 status = "okay"; 411}; 412