Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 1 | /* |
| 2 | * This program is free software; you can redistribute it and/or modify |
| 3 | * it under the terms of the GNU General Public License as published by |
| 4 | * the Free Software Foundation; either version 2 of the License, or |
| 5 | * (at your option) any later version. |
| 6 | * |
| 7 | * This program is distributed in the hope that it will be useful, |
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 10 | * GNU General Public License for more details. |
| 11 | */ |
| 12 | |
Doug Anderson | 0541f94 | 2014-08-25 15:59:27 -0700 | [diff] [blame] | 13 | #include <dt-bindings/pwm/pwm.h> |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 14 | #include "rk3288.dtsi" |
| 15 | |
| 16 | / { |
| 17 | memory { |
| 18 | reg = <0x0 0x80000000>; |
| 19 | }; |
| 20 | |
Doug Anderson | 0541f94 | 2014-08-25 15:59:27 -0700 | [diff] [blame] | 21 | backlight { |
| 22 | compatible = "pwm-backlight"; |
| 23 | brightness-levels = < |
| 24 | 0 1 2 3 4 5 6 7 |
| 25 | 8 9 10 11 12 13 14 15 |
| 26 | 16 17 18 19 20 21 22 23 |
| 27 | 24 25 26 27 28 29 30 31 |
| 28 | 32 33 34 35 36 37 38 39 |
| 29 | 40 41 42 43 44 45 46 47 |
| 30 | 48 49 50 51 52 53 54 55 |
| 31 | 56 57 58 59 60 61 62 63 |
| 32 | 64 65 66 67 68 69 70 71 |
| 33 | 72 73 74 75 76 77 78 79 |
| 34 | 80 81 82 83 84 85 86 87 |
| 35 | 88 89 90 91 92 93 94 95 |
| 36 | 96 97 98 99 100 101 102 103 |
| 37 | 104 105 106 107 108 109 110 111 |
| 38 | 112 113 114 115 116 117 118 119 |
| 39 | 120 121 122 123 124 125 126 127 |
| 40 | 128 129 130 131 132 133 134 135 |
| 41 | 136 137 138 139 140 141 142 143 |
| 42 | 144 145 146 147 148 149 150 151 |
| 43 | 152 153 154 155 156 157 158 159 |
| 44 | 160 161 162 163 164 165 166 167 |
| 45 | 168 169 170 171 172 173 174 175 |
| 46 | 176 177 178 179 180 181 182 183 |
| 47 | 184 185 186 187 188 189 190 191 |
| 48 | 192 193 194 195 196 197 198 199 |
| 49 | 200 201 202 203 204 205 206 207 |
| 50 | 208 209 210 211 212 213 214 215 |
| 51 | 216 217 218 219 220 221 222 223 |
| 52 | 224 225 226 227 228 229 230 231 |
| 53 | 232 233 234 235 236 237 238 239 |
| 54 | 240 241 242 243 244 245 246 247 |
| 55 | 248 249 250 251 252 253 254 255>; |
| 56 | default-brightness-level = <128>; |
| 57 | enable-gpios = <&gpio7 2 GPIO_ACTIVE_HIGH>; |
| 58 | pinctrl-names = "default"; |
| 59 | pinctrl-0 = <&bl_en>; |
| 60 | pwms = <&pwm0 0 1000000 PWM_POLARITY_INVERTED>; |
| 61 | }; |
| 62 | |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 63 | gpio-keys { |
| 64 | compatible = "gpio-keys"; |
| 65 | #address-cells = <1>; |
| 66 | #size-cells = <0>; |
| 67 | autorepeat; |
| 68 | |
| 69 | pinctrl-names = "default"; |
| 70 | pinctrl-0 = <&pwrbtn>; |
| 71 | |
| 72 | button@0 { |
| 73 | gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; |
| 74 | linux,code = <116>; |
| 75 | label = "GPIO Key Power"; |
| 76 | linux,input-type = <1>; |
| 77 | gpio-key,wakeup = <1>; |
| 78 | debounce-interval = <100>; |
| 79 | }; |
| 80 | }; |
Doug Anderson | 83a742b | 2014-07-30 13:00:10 -0700 | [diff] [blame] | 81 | |
| 82 | /* This turns on USB vbus for both host0 (ehci) and host1 (dwc2) */ |
| 83 | vcc_host: vcc-host-regulator { |
| 84 | compatible = "regulator-fixed"; |
| 85 | enable-active-high; |
| 86 | gpio = <&gpio0 14 GPIO_ACTIVE_HIGH>; |
| 87 | pinctrl-names = "default"; |
| 88 | pinctrl-0 = <&host_vbus_drv>; |
| 89 | regulator-name = "vcc_host"; |
| 90 | regulator-always-on; |
| 91 | regulator-boot-on; |
| 92 | }; |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 93 | }; |
| 94 | |
Doug Anderson | 2c31d94 | 2014-08-12 16:21:14 -0700 | [diff] [blame] | 95 | &emmc { |
| 96 | broken-cd; |
| 97 | bus-width = <8>; |
| 98 | cap-mmc-highspeed; |
| 99 | disable-wp; |
| 100 | non-removable; |
| 101 | num-slots = <1>; |
| 102 | pinctrl-names = "default"; |
| 103 | pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_pwr &emmc_bus8>; |
| 104 | status = "okay"; |
| 105 | }; |
| 106 | |
| 107 | &sdmmc { |
| 108 | bus-width = <4>; |
| 109 | cap-mmc-highspeed; |
| 110 | cap-sd-highspeed; |
| 111 | card-detect-delay = <200>; |
| 112 | disable-wp; /* wp not hooked up */ |
| 113 | num-slots = <1>; |
| 114 | pinctrl-names = "default"; |
| 115 | pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_cd &sdmmc_bus4>; |
| 116 | status = "okay"; |
| 117 | }; |
| 118 | |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 119 | &i2c0 { |
| 120 | status = "okay"; |
| 121 | }; |
| 122 | |
| 123 | &wdt { |
| 124 | status = "okay"; |
| 125 | }; |
| 126 | |
Doug Anderson | 0541f94 | 2014-08-25 15:59:27 -0700 | [diff] [blame] | 127 | &pwm0 { |
| 128 | status = "okay"; |
| 129 | }; |
| 130 | |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 131 | &uart0 { |
| 132 | status = "okay"; |
| 133 | }; |
| 134 | |
| 135 | &uart1 { |
| 136 | status = "okay"; |
| 137 | }; |
| 138 | |
| 139 | &uart2 { |
| 140 | status = "okay"; |
| 141 | }; |
| 142 | |
| 143 | &uart3 { |
| 144 | status = "okay"; |
| 145 | }; |
| 146 | |
| 147 | &uart4 { |
| 148 | status = "okay"; |
| 149 | }; |
| 150 | |
Caesar Wang | ff9d0ec | 2014-11-24 12:59:02 +0800 | [diff] [blame] | 151 | &tsadc { |
| 152 | rockchip,hw-tshut-mode = <0>; /* tshut mode 0:CRU 1:GPIO */ |
| 153 | rockchip,hw-tshut-polarity = <0>; /* tshut polarity 0:LOW 1:HIGH */ |
| 154 | status = "okay"; |
| 155 | }; |
| 156 | |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 157 | &pinctrl { |
Doug Anderson | 0541f94 | 2014-08-25 15:59:27 -0700 | [diff] [blame] | 158 | backlight { |
| 159 | bl_en: bl-en { |
| 160 | rockchip,pins = <7 2 RK_FUNC_GPIO &pcfg_pull_none>; |
| 161 | }; |
| 162 | }; |
| 163 | |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 164 | buttons { |
| 165 | pwrbtn: pwrbtn { |
| 166 | rockchip,pins = <0 5 RK_FUNC_GPIO &pcfg_pull_up>; |
| 167 | }; |
| 168 | }; |
Doug Anderson | 83a742b | 2014-07-30 13:00:10 -0700 | [diff] [blame] | 169 | |
Doug Anderson | 91ff8cd | 2014-08-11 11:47:29 -0700 | [diff] [blame] | 170 | pmic { |
| 171 | pmic_int: pmic-int { |
| 172 | rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>; |
| 173 | }; |
| 174 | }; |
| 175 | |
Doug Anderson | 83a742b | 2014-07-30 13:00:10 -0700 | [diff] [blame] | 176 | usb { |
| 177 | host_vbus_drv: host-vbus-drv { |
| 178 | rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>; |
| 179 | }; |
| 180 | }; |
Heiko Stuebner | 6ce0562 | 2014-07-15 20:09:44 +0200 | [diff] [blame] | 181 | }; |
Doug Anderson | 163cb91 | 2014-07-30 13:00:12 -0700 | [diff] [blame] | 182 | |
| 183 | &usb_host0_ehci { |
| 184 | status = "okay"; |
| 185 | }; |
Kever Yang | ddf8303 | 2014-08-08 11:55:59 +0800 | [diff] [blame] | 186 | |
| 187 | &usb_host1 { |
| 188 | status = "okay"; |
| 189 | }; |