Tom Rini | 53633a8 | 2024-02-29 12:33:36 -0500 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0 |
| 2 | /* |
| 3 | * TOPEET's Exynos4412 based itop board device tree source |
| 4 | * |
| 5 | * Copyright (c) 2016 SUMOMO Computer Association |
| 6 | * https://www.sumomo.mobi |
| 7 | * Randy Li <ayaka@soulik.info> |
| 8 | * |
| 9 | * Device tree source file for TOPEET iTop Exynos 4412 core board |
| 10 | * which is based on Samsung's Exynos4412 SoC. |
| 11 | */ |
| 12 | |
| 13 | /dts-v1/; |
| 14 | #include <dt-bindings/leds/common.h> |
| 15 | #include <dt-bindings/pwm/pwm.h> |
| 16 | #include <dt-bindings/sound/samsung-i2s.h> |
| 17 | #include "exynos4412-itop-scp-core.dtsi" |
| 18 | |
| 19 | / { |
| 20 | model = "TOPEET iTop 4412 Elite board based on Exynos4412"; |
| 21 | compatible = "topeet,itop4412-elite", "samsung,exynos4412", "samsung,exynos4"; |
| 22 | |
| 23 | aliases { |
| 24 | mmc1 = &sdhci_2; |
| 25 | }; |
| 26 | |
| 27 | chosen { |
| 28 | bootargs = "root=/dev/mmcblk0p2 rw rootfstype=ext4 rootdelay=1 rootwait"; |
| 29 | stdout-path = "serial2:115200n8"; |
| 30 | }; |
| 31 | |
| 32 | leds { |
| 33 | compatible = "gpio-leds"; |
| 34 | |
| 35 | led2 { |
| 36 | function = LED_FUNCTION_HEARTBEAT; |
| 37 | color = <LED_COLOR_ID_RED>; |
| 38 | gpios = <&gpx1 0 GPIO_ACTIVE_HIGH>; |
| 39 | default-state = "off"; |
| 40 | linux,default-trigger = "heartbeat"; |
| 41 | }; |
| 42 | |
| 43 | led3 { |
| 44 | label = "red:user"; |
| 45 | color = <LED_COLOR_ID_RED>; |
| 46 | gpios = <&gpk1 1 GPIO_ACTIVE_HIGH>; |
| 47 | default-state = "off"; |
| 48 | }; |
| 49 | }; |
| 50 | |
| 51 | gpio-keys { |
| 52 | compatible = "gpio-keys"; |
| 53 | |
| 54 | key-home { |
| 55 | label = "GPIO Key Home"; |
| 56 | linux,code = <KEY_HOME>; |
| 57 | gpios = <&gpx1 1 GPIO_ACTIVE_LOW>; |
| 58 | }; |
| 59 | |
| 60 | key-back { |
| 61 | label = "GPIO Key Back"; |
| 62 | linux,code = <KEY_BACK>; |
| 63 | gpios = <&gpx1 2 GPIO_ACTIVE_LOW>; |
| 64 | }; |
| 65 | |
| 66 | key-sleep { |
| 67 | label = "GPIO Key Sleep"; |
| 68 | linux,code = <KEY_POWER>; |
| 69 | gpios = <&gpx3 3 GPIO_ACTIVE_LOW>; |
| 70 | }; |
| 71 | |
| 72 | key-vol-up { |
| 73 | label = "GPIO Key Vol+"; |
| 74 | linux,code = <KEY_UP>; |
| 75 | gpios = <&gpx2 1 GPIO_ACTIVE_LOW>; |
| 76 | }; |
| 77 | |
| 78 | key-vol-down { |
| 79 | label = "GPIO Key Vol-"; |
| 80 | linux,code = <KEY_DOWN>; |
| 81 | gpios = <&gpx2 0 GPIO_ACTIVE_LOW>; |
| 82 | }; |
| 83 | }; |
| 84 | |
| 85 | sound { |
| 86 | compatible = "simple-audio-card"; |
| 87 | simple-audio-card,name = "wm-sound"; |
| 88 | |
| 89 | simple-audio-card,format = "i2s"; |
| 90 | simple-audio-card,bitclock-master = <&link0_codec>; |
| 91 | simple-audio-card,frame-master = <&link0_codec>; |
| 92 | |
| 93 | simple-audio-card,widgets = |
| 94 | "Microphone", "Mic Jack", |
| 95 | "Line", "Line In", |
| 96 | "Line", "Line Out", |
| 97 | "Speaker", "Speaker", |
| 98 | "Headphone", "Headphone Jack"; |
| 99 | simple-audio-card,routing = |
| 100 | "Headphone Jack", "HP_L", |
| 101 | "Headphone Jack", "HP_R", |
| 102 | "Speaker", "SPK_LP", |
| 103 | "Speaker", "SPK_LN", |
| 104 | "Speaker", "SPK_RP", |
| 105 | "Speaker", "SPK_RN", |
| 106 | "LINPUT1", "Mic Jack", |
| 107 | "LINPUT3", "Mic Jack", |
| 108 | "RINPUT1", "Mic Jack", |
| 109 | "RINPUT2", "Mic Jack"; |
| 110 | |
| 111 | simple-audio-card,cpu { |
| 112 | sound-dai = <&i2s0 0>; |
| 113 | }; |
| 114 | |
| 115 | link0_codec: simple-audio-card,codec { |
| 116 | sound-dai = <&codec>; |
| 117 | clocks = <&i2s0 CLK_I2S_CDCLK>; |
| 118 | system-clock-frequency = <11289600>; |
| 119 | }; |
| 120 | }; |
| 121 | |
| 122 | beep { |
| 123 | compatible = "pwm-beeper"; |
| 124 | pwms = <&pwm 0 4000000 PWM_POLARITY_INVERTED>; |
| 125 | }; |
| 126 | }; |
| 127 | |
| 128 | &adc { |
| 129 | vdd-supply = <&ldo3_reg>; |
| 130 | status = "okay"; |
| 131 | }; |
| 132 | |
| 133 | &camera { |
| 134 | pinctrl-0 = <&cam_port_a_clk_active>; |
| 135 | pinctrl-names = "default"; |
| 136 | status = "okay"; |
| 137 | assigned-clocks = <&clock CLK_MOUT_CAM0>; |
| 138 | assigned-clock-parents = <&clock CLK_XUSBXTI>; |
| 139 | }; |
| 140 | |
| 141 | &clock_audss { |
| 142 | assigned-clocks = <&clock_audss EXYNOS_MOUT_AUDSS>, |
| 143 | <&clock_audss EXYNOS_MOUT_I2S>, |
| 144 | <&clock_audss EXYNOS_DOUT_SRP>, |
| 145 | <&clock_audss EXYNOS_DOUT_AUD_BUS>; |
| 146 | assigned-clock-parents = <&clock CLK_FOUT_EPLL>, |
| 147 | <&clock_audss EXYNOS_MOUT_AUDSS>; |
| 148 | assigned-clock-rates = <0>, <0>, <112896000>, <11289600>; |
| 149 | }; |
| 150 | |
| 151 | &ehci { |
| 152 | status = "okay"; |
| 153 | /* In order to reset USB ethernet */ |
| 154 | samsung,vbus-gpio = <&gpc0 1 GPIO_ACTIVE_HIGH>; |
| 155 | |
| 156 | phys = <&exynos_usbphy 1>, <&exynos_usbphy 3>; |
| 157 | phy-names = "host", "hsic1"; |
| 158 | }; |
| 159 | |
| 160 | &exynos_usbphy { |
| 161 | status = "okay"; |
| 162 | }; |
| 163 | |
| 164 | &fimc_0 { |
| 165 | status = "okay"; |
| 166 | assigned-clocks = <&clock CLK_MOUT_FIMC0>, |
| 167 | <&clock CLK_SCLK_FIMC0>; |
| 168 | assigned-clock-parents = <&clock CLK_MOUT_MPLL_USER_T>; |
| 169 | assigned-clock-rates = <0>, <176000000>; |
| 170 | }; |
| 171 | |
| 172 | &hsotg { |
| 173 | dr_mode = "peripheral"; |
| 174 | status = "okay"; |
| 175 | }; |
| 176 | |
| 177 | &i2c_4 { |
| 178 | samsung,i2c-sda-delay = <100>; |
| 179 | samsung,i2c-slave-addr = <0x10>; |
| 180 | samsung,i2c-max-bus-freq = <100000>; |
| 181 | pinctrl-0 = <&i2c4_bus>; |
| 182 | pinctrl-names = "default"; |
| 183 | status = "okay"; |
| 184 | |
| 185 | codec: audio-codec@1a { |
| 186 | compatible = "wlf,wm8960"; |
| 187 | reg = <0x1a>; |
| 188 | clocks = <&pmu_system_controller 0>; |
| 189 | clock-names = "mclk"; |
| 190 | wlf,shared-lrclk; |
| 191 | #sound-dai-cells = <0>; |
| 192 | }; |
| 193 | }; |
| 194 | |
| 195 | &i2s0 { |
| 196 | pinctrl-0 = <&i2s0_bus>; |
| 197 | pinctrl-names = "default"; |
| 198 | status = "okay"; |
| 199 | }; |
| 200 | |
| 201 | &pinctrl_1 { |
| 202 | ether-reset-pins { |
| 203 | samsung,pins = "gpc0-1"; |
| 204 | samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>; |
| 205 | samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; |
| 206 | samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; |
| 207 | }; |
| 208 | }; |
| 209 | |
| 210 | &pwm { |
| 211 | status = "okay"; |
| 212 | pinctrl-0 = <&pwm0_out>; |
| 213 | pinctrl-names = "default"; |
| 214 | samsung,pwm-outputs = <0>; |
| 215 | }; |
| 216 | |
| 217 | &sdhci_2 { |
| 218 | bus-width = <4>; |
| 219 | pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_bus4>; |
| 220 | pinctrl-names = "default"; |
| 221 | cd-gpios = <&gpx0 7 GPIO_ACTIVE_LOW>; |
| 222 | cap-sd-highspeed; |
| 223 | vmmc-supply = <&ldo23_reg>; |
| 224 | vqmmc-supply = <&ldo17_reg>; |
| 225 | status = "okay"; |
| 226 | }; |
| 227 | |
| 228 | &serial_1 { |
| 229 | status = "okay"; |
| 230 | }; |
| 231 | |
| 232 | &serial_2 { |
| 233 | status = "okay"; |
| 234 | }; |