diff --git a/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts b/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts index bdfb015d9019..f6253cfd9033 100644 --- a/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts +++ b/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts @@ -1,381 +1,9 @@ -// SPDX-License-Identifier: (GPL-2.0+ OR MIT) /* - * Copyright (c) 2021 Hardkernel Co., Ltd. + * Copyright (c) 2024 Hardkernel Co., Ltd. * */ /dts-v1/; -#include "rk3568-odroid.dtsi" +#include "rk3568-odroid-m1.dtsi" #include "rk3568-linux.dtsi" - -/ { - model = "Hardkernel ODROID-M1"; - - aliases { - serial0 = &uart1; - serial1 = &uart0; - i2c0 = &i2c3; - i2c3 = &i2c0; - }; - - backlight: backlight { - compatible = "pwm-backlight"; - status = "disabled"; - - pwms = <&pwm4 0 25000 0>; - brightness-levels = < - 0 20 20 21 21 22 22 23 - 23 24 24 25 25 26 26 27 - 27 28 28 29 29 30 30 31 - 31 32 32 33 33 34 34 35 - 35 36 36 37 37 38 38 39 - 40 41 42 43 44 45 46 47 - 48 49 50 51 52 53 54 55 - 56 57 58 59 60 61 62 63 - 64 65 66 67 68 69 70 71 - 72 73 74 75 76 77 78 79 - 80 81 82 83 84 85 86 87 - 88 89 90 91 92 93 94 95 - 96 97 98 99 100 101 102 103 - 104 105 106 107 108 109 110 111 - 112 113 114 115 116 117 118 119 - 120 121 122 123 124 125 126 127 - 128 129 130 131 132 133 134 135 - 136 137 138 139 140 141 142 143 - 144 145 146 147 148 149 150 151 - 152 153 154 155 156 157 158 159 - 160 161 162 163 164 165 166 167 - 168 169 170 171 172 173 174 175 - 176 177 178 179 180 181 182 183 - 184 185 186 187 188 189 190 191 - 192 193 194 195 196 197 198 199 - 200 201 202 203 204 205 206 207 - 208 209 210 211 212 213 214 215 - 216 217 218 219 220 221 222 223 - 224 225 226 227 228 229 230 231 - 232 233 234 235 236 237 238 239 - 240 241 242 243 244 245 246 247 - 248 249 250 251 252 253 254 255 - >; - default-brightness-level = <200>; - }; - - lcd_pwren: lcd-pwren { - compatible = "regulator-fixed"; - enable-active-high; - gpio = <&gpio0 RK_PC7 GPIO_ACTIVE_HIGH>; - pinctrl-0 = <&lcd_pwr_en>; - pinctrl-names = "default"; - regulator-always-on; - regulator-boot-on; - regulator-name = "lcd_pwren"; - vin-supply = <&vcc3v3_sys>; - }; - - pcie30_avdd0v9: pcie30-avdd0v9 { - compatible = "regulator-fixed"; - regulator-name = "pcie30_avdd0v9"; - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <900000>; - regulator-max-microvolt = <900000>; - vin-supply = <&vcc3v3_sys>; - }; - - pcie30_avdd1v8: pcie30-avdd1v8 { - compatible = "regulator-fixed"; - regulator-name = "pcie30_avdd1v8"; - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; - vin-supply = <&vcc3v3_sys>; - }; - - vcc3v3_pcie: gpio-regulator { - compatible = "regulator-fixed"; - regulator-name = "vcc3v3_pcie"; - enable-active-high; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - gpio = <&gpio4 RK_PA7 GPIO_ACTIVE_HIGH>; - startup-delay-us = <5000>; - vin-supply = <&dc_12v>; - }; -}; - -&can0 { - pinctrl-names = "default"; - pinctrl-0 = <&can0m0_pins>; - assigned-clocks = <&cru CLK_CAN0>; - assigned-clock-rates = <200000000>; - status = "disabled"; -}; - -&combphy0_us { - status = "okay"; -}; - -&combphy1_usq { - status = "okay"; -}; - -&combphy2_psq { - status = "okay"; -}; - -&dsi0 { - status = "disabled"; - - connect = <&vp1_out_dsi0>; - - dsi0_panel: panel@0 { - #address-cells = <1>; - #size-cells = <0>; - - /delete-property/ disable-delay-ms; - /delete-property/ enable-delay-ms; - /delete-property/ panel-exit-sequence; - /delete-property/ panel-init-sequence; - /delete-property/ reset-delay-ms; - /delete-property/ prepare-delay-ms; - /delete-property/ unprepare-delay-ms; - - status = "disabled"; - - reg = <0>; - - backlight = <&backlight>; - power-supply = <&lcd_pwren>; - - reset-gpios = <&gpio2 RK_PC6 GPIO_ACTIVE_LOW>; - - pinctrl-names = "default"; - pinctrl-0 = <&lcd_rst_gpio>; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - - panel_in_dsi: endpoint { - remote-endpoint = <&dsi_out_panel>; - }; - }; - }; - }; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@1 { - reg = <1>; - - dsi_out_panel: endpoint { - remote-endpoint = <&panel_in_dsi>; - }; - }; - }; -}; - -&gpio0 { - gpio-line-names = - /* GPIO0_A */ - "", "", "", "", "", "", "", "", - /* GPIO0_B */ - "", "", "", - "PIN_28", /* GPIO0_B3 */ - "PIN_27", /* GPIO0_B4 */ - "PIN_33", /* GPIO0_B5 */ - "PIN_7", /* GPIO0_B6 */ - "", - /* GPIO0_C */ - "PIN_11", /* GPIO0_C0 */ - "PIN_13", /* GPIO0_C1 */ - "", "", "", "", "", "", - /* GPIO0_D */ - "", "", "", "", "", "", "", ""; -}; - -&gpio1 { - gpio-line-names = - /* GPIO1_A */ - "", "", "", "", "", "", "", "", - /* GPIO1_B */ - "", "", "", "", "", "", "", "", - /* GPIO1_C */ - "", "", "", "", "", "", "", "", - /* GPIO1_D */ - "", "", "", "", "", "", "", ""; -}; - -&gpio2 { - gpio-line-names = - /* GPIO2_A */ - "", "", "", "", "", "", "", "", - /* GPIO2_B */ - "", "", "", "", "", "", "", "", - /* GPIO2_C */ - "", "", "", "", "", "", "", "", - /* GPIO2_D */ - "PIN_21", /* GPIO2_D0 */ - "PIN_19", /* GPIO2_D1 */ - "PIN_24", /* GPIO2_D2 */ - "PIN_23", /* GPIO2_D3 */ - "", "", "", ""; -}; - -&gpio3 { - gpio-line-names = - /* GPIO3_A */ - "", "", "", "", "", "", "", "", - /* GPIO3_B */ - "", "", - "PIN_15", /* GPIO3_B2 */ - "", "", - "PIN_5", /* GPIO3_B5 */ - "PIN_3", /* GPIO3_B6 */ - "", - /* GPIO3_C */ - "", "", "", "", "", "", - "PIN_16", /* GPIO3_C6 */ - "PIN_18", /* GPIO3_C7 */ - /* GPIO3_D */ - "PIN_12", /* GPIO3_D0 */ - "PIN_22", /* GPIO3_D1 */ - "PIN_26", /* GPIO3_D2 */ - "PIN_32", /* GPIO3_D3 */ - "PIN_36", /* GPIO3_D4 */ - "PIN_35", /* GPIO3_D5 */ - "PIN_8", /* GPIO3_D6 */ - "PIN_10"; /* GPIO3_D7 */ -}; - -&gpio4 { - gpio-line-names = - /* GPIO4_A */ - "", "", "", "", "", "", "", "", - /* GPIO4_B */ - "", "", "", "", "", "", - "PIN_31", /* GPIO4_B6 */ - "", - /* GPIO4_C */ - "", - "PIN_29", /* GPIO4_C1 */ - "", "", "", - "", "", "", - /* GPIO4_D */ - "", "", "", "", "", "", "", ""; -}; - -&hdmi_sound { - simple-audio-card,name = "ODROID-M1-HDMI"; - status = "okay"; -}; - -&i2c3 { - status = "disabled"; - pinctrl-names = "default"; - pinctrl-0 = <&i2c3m1_xfer>; -}; - -&i2c4 { - status = "disabled"; - - clock-frequency = <400000>; - - touchscreen: touchscreen { - status = "disabled"; - - pinctrl-names = "default"; - pinctrl-0 = <&touch_gpios>; - - interrupt-parent = <&gpio0>; - interrupts = ; - - irq-gpios = <&gpio0 RK_PC4 IRQ_TYPE_LEVEL_LOW>; - reset-gpios = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>; - }; -}; - -&pcie30phy { - status = "okay"; -}; - -&pcie3x2 { - reset-gpios = <&gpio2 RK_PD6 GPIO_ACTIVE_HIGH>; - vpcie3v3-supply = <&vcc3v3_pcie>; - status = "okay"; -}; - -&pinctrl { - lcd { - lcd_pwr_en: lcd-pwr-en { - rockchip,pins = <0 RK_PC7 RK_FUNC_GPIO &pcfg_pull_none>; - }; - - lcd_rst_gpio: lcd-rst-gpio { - rockchip,pins = <2 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>; - }; - - touch_gpios: touch-gpios { - rockchip,pins = - <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>, - <0 RK_PC4 RK_FUNC_GPIO &pcfg_pull_up>; - }; - }; -}; - -&pwm1 { - status = "disabled"; - pinctrl-0 = <&pwm1m1_pins>; -}; - -&pwm2 { - status = "disabled"; - pinctrl-0 = <&pwm2m1_pins>; -}; - -&reserved_memory { - pcie3x2@80900000{ - reg = <0x0 0x80900000 0x0 0x100000>; - }; -}; - -&rk809_sound { - rockchip,card-name = "ODROID-M1-FRONT"; - status = "okay"; -}; - -&sata2 { - status = "okay"; -}; - -&sfc { - status = "okay"; - - pinctrl-names = "default"; - pinctrl-0 = <&fspi_pins>; -}; - -&spi0 { - status = "disabled"; - - pinctrl-0 = <&spi0m1_pins>; - pinctrl-1 = <&spi0m1_pins_hs>; - num_chipselect = <1>; - - cs-gpios = <&gpio2 RK_PD2 GPIO_ACTIVE_LOW>; -}; - -&uart1 { - status = "disabled"; - dma-names = "tx", "rx"; - /* uart1 uart1-with-ctsrts */ - pinctrl-0 = <&uart1m1_xfer>; - pinctrl-1 = <&uart1m1_xfer &uart1m1_ctsn &uart1m1_rtsn>; -}; diff --git a/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dtsi b/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dtsi new file mode 100644 index 000000000000..daaba0d9e02a --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dtsi @@ -0,0 +1,380 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +/* + * Copyright (c) 2021 Hardkernel Co., Ltd. + * + */ + +/dts-v1/; + +#include "rk3568-odroid.dtsi" + +/ { + model = "Hardkernel ODROID-M1"; + + aliases { + serial0 = &uart1; + serial1 = &uart0; + i2c0 = &i2c3; + i2c3 = &i2c0; + }; + + backlight: backlight { + compatible = "pwm-backlight"; + status = "disabled"; + + pwms = <&pwm4 0 25000 0>; + brightness-levels = < + 0 20 20 21 21 22 22 23 + 23 24 24 25 25 26 26 27 + 27 28 28 29 29 30 30 31 + 31 32 32 33 33 34 34 35 + 35 36 36 37 37 38 38 39 + 40 41 42 43 44 45 46 47 + 48 49 50 51 52 53 54 55 + 56 57 58 59 60 61 62 63 + 64 65 66 67 68 69 70 71 + 72 73 74 75 76 77 78 79 + 80 81 82 83 84 85 86 87 + 88 89 90 91 92 93 94 95 + 96 97 98 99 100 101 102 103 + 104 105 106 107 108 109 110 111 + 112 113 114 115 116 117 118 119 + 120 121 122 123 124 125 126 127 + 128 129 130 131 132 133 134 135 + 136 137 138 139 140 141 142 143 + 144 145 146 147 148 149 150 151 + 152 153 154 155 156 157 158 159 + 160 161 162 163 164 165 166 167 + 168 169 170 171 172 173 174 175 + 176 177 178 179 180 181 182 183 + 184 185 186 187 188 189 190 191 + 192 193 194 195 196 197 198 199 + 200 201 202 203 204 205 206 207 + 208 209 210 211 212 213 214 215 + 216 217 218 219 220 221 222 223 + 224 225 226 227 228 229 230 231 + 232 233 234 235 236 237 238 239 + 240 241 242 243 244 245 246 247 + 248 249 250 251 252 253 254 255 + >; + default-brightness-level = <200>; + }; + + lcd_pwren: lcd-pwren { + compatible = "regulator-fixed"; + enable-active-high; + gpio = <&gpio0 RK_PC7 GPIO_ACTIVE_HIGH>; + pinctrl-0 = <&lcd_pwr_en>; + pinctrl-names = "default"; + regulator-always-on; + regulator-boot-on; + regulator-name = "lcd_pwren"; + vin-supply = <&vcc3v3_sys>; + }; + + pcie30_avdd0v9: pcie30-avdd0v9 { + compatible = "regulator-fixed"; + regulator-name = "pcie30_avdd0v9"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <900000>; + regulator-max-microvolt = <900000>; + vin-supply = <&vcc3v3_sys>; + }; + + pcie30_avdd1v8: pcie30-avdd1v8 { + compatible = "regulator-fixed"; + regulator-name = "pcie30_avdd1v8"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + vin-supply = <&vcc3v3_sys>; + }; + + vcc3v3_pcie: gpio-regulator { + compatible = "regulator-fixed"; + regulator-name = "vcc3v3_pcie"; + enable-active-high; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + gpio = <&gpio4 RK_PA7 GPIO_ACTIVE_HIGH>; + startup-delay-us = <5000>; + vin-supply = <&dc_12v>; + }; +}; + +&can0 { + pinctrl-names = "default"; + pinctrl-0 = <&can0m0_pins>; + assigned-clocks = <&cru CLK_CAN0>; + assigned-clock-rates = <200000000>; + status = "disabled"; +}; + +&combphy0_us { + status = "okay"; +}; + +&combphy1_usq { + status = "okay"; +}; + +&combphy2_psq { + status = "okay"; +}; + +&dsi0 { + status = "disabled"; + + connect = <&vp1_out_dsi0>; + + dsi0_panel: panel@0 { + #address-cells = <1>; + #size-cells = <0>; + + /delete-property/ disable-delay-ms; + /delete-property/ enable-delay-ms; + /delete-property/ panel-exit-sequence; + /delete-property/ panel-init-sequence; + /delete-property/ reset-delay-ms; + /delete-property/ prepare-delay-ms; + /delete-property/ unprepare-delay-ms; + + status = "disabled"; + + reg = <0>; + + backlight = <&backlight>; + power-supply = <&lcd_pwren>; + + reset-gpios = <&gpio2 RK_PC6 GPIO_ACTIVE_LOW>; + + pinctrl-names = "default"; + pinctrl-0 = <&lcd_rst_gpio>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + panel_in_dsi: endpoint { + remote-endpoint = <&dsi_out_panel>; + }; + }; + }; + }; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@1 { + reg = <1>; + + dsi_out_panel: endpoint { + remote-endpoint = <&panel_in_dsi>; + }; + }; + }; +}; + +&gpio0 { + gpio-line-names = + /* GPIO0_A */ + "", "", "", "", "", "", "", "", + /* GPIO0_B */ + "", "", "", + "PIN_28", /* GPIO0_B3 */ + "PIN_27", /* GPIO0_B4 */ + "PIN_33", /* GPIO0_B5 */ + "PIN_7", /* GPIO0_B6 */ + "", + /* GPIO0_C */ + "PIN_11", /* GPIO0_C0 */ + "PIN_13", /* GPIO0_C1 */ + "", "", "", "", "", "", + /* GPIO0_D */ + "", "", "", "", "", "", "", ""; +}; + +&gpio1 { + gpio-line-names = + /* GPIO1_A */ + "", "", "", "", "", "", "", "", + /* GPIO1_B */ + "", "", "", "", "", "", "", "", + /* GPIO1_C */ + "", "", "", "", "", "", "", "", + /* GPIO1_D */ + "", "", "", "", "", "", "", ""; +}; + +&gpio2 { + gpio-line-names = + /* GPIO2_A */ + "", "", "", "", "", "", "", "", + /* GPIO2_B */ + "", "", "", "", "", "", "", "", + /* GPIO2_C */ + "", "", "", "", "", "", "", "", + /* GPIO2_D */ + "PIN_21", /* GPIO2_D0 */ + "PIN_19", /* GPIO2_D1 */ + "PIN_24", /* GPIO2_D2 */ + "PIN_23", /* GPIO2_D3 */ + "", "", "", ""; +}; + +&gpio3 { + gpio-line-names = + /* GPIO3_A */ + "", "", "", "", "", "", "", "", + /* GPIO3_B */ + "", "", + "PIN_15", /* GPIO3_B2 */ + "", "", + "PIN_5", /* GPIO3_B5 */ + "PIN_3", /* GPIO3_B6 */ + "", + /* GPIO3_C */ + "", "", "", "", "", "", + "PIN_16", /* GPIO3_C6 */ + "PIN_18", /* GPIO3_C7 */ + /* GPIO3_D */ + "PIN_12", /* GPIO3_D0 */ + "PIN_22", /* GPIO3_D1 */ + "PIN_26", /* GPIO3_D2 */ + "PIN_32", /* GPIO3_D3 */ + "PIN_36", /* GPIO3_D4 */ + "PIN_35", /* GPIO3_D5 */ + "PIN_8", /* GPIO3_D6 */ + "PIN_10"; /* GPIO3_D7 */ +}; + +&gpio4 { + gpio-line-names = + /* GPIO4_A */ + "", "", "", "", "", "", "", "", + /* GPIO4_B */ + "", "", "", "", "", "", + "PIN_31", /* GPIO4_B6 */ + "", + /* GPIO4_C */ + "", + "PIN_29", /* GPIO4_C1 */ + "", "", "", + "", "", "", + /* GPIO4_D */ + "", "", "", "", "", "", "", ""; +}; + +&hdmi_sound { + simple-audio-card,name = "ODROID-M1-HDMI"; + status = "okay"; +}; + +&i2c3 { + status = "disabled"; + pinctrl-names = "default"; + pinctrl-0 = <&i2c3m1_xfer>; +}; + +&i2c4 { + status = "disabled"; + + clock-frequency = <400000>; + + touchscreen: touchscreen { + status = "disabled"; + + pinctrl-names = "default"; + pinctrl-0 = <&touch_gpios>; + + interrupt-parent = <&gpio0>; + interrupts = ; + + irq-gpios = <&gpio0 RK_PC4 IRQ_TYPE_LEVEL_LOW>; + reset-gpios = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>; + }; +}; + +&pcie30phy { + status = "okay"; +}; + +&pcie3x2 { + reset-gpios = <&gpio2 RK_PD6 GPIO_ACTIVE_HIGH>; + vpcie3v3-supply = <&vcc3v3_pcie>; + status = "okay"; +}; + +&pinctrl { + lcd { + lcd_pwr_en: lcd-pwr-en { + rockchip,pins = <0 RK_PC7 RK_FUNC_GPIO &pcfg_pull_none>; + }; + + lcd_rst_gpio: lcd-rst-gpio { + rockchip,pins = <2 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>; + }; + + touch_gpios: touch-gpios { + rockchip,pins = + <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>, + <0 RK_PC4 RK_FUNC_GPIO &pcfg_pull_up>; + }; + }; +}; + +&pwm1 { + status = "disabled"; + pinctrl-0 = <&pwm1m1_pins>; +}; + +&pwm2 { + status = "disabled"; + pinctrl-0 = <&pwm2m1_pins>; +}; + +&reserved_memory { + pcie3x2@80900000{ + reg = <0x0 0x80900000 0x0 0x100000>; + }; +}; + +&rk809_sound { + rockchip,card-name = "ODROID-M1-FRONT"; + status = "okay"; +}; + +&sata2 { + status = "okay"; +}; + +&sfc { + status = "okay"; + + pinctrl-names = "default"; + pinctrl-0 = <&fspi_pins>; +}; + +&spi0 { + status = "disabled"; + + pinctrl-0 = <&spi0m1_pins>; + pinctrl-1 = <&spi0m1_pins_hs>; + num_chipselect = <1>; + + cs-gpios = <&gpio2 RK_PD2 GPIO_ACTIVE_LOW>; +}; + +&uart1 { + status = "disabled"; + dma-names = "tx", "rx"; + /* uart1 uart1-with-ctsrts */ + pinctrl-0 = <&uart1m1_xfer>; + pinctrl-1 = <&uart1m1_xfer &uart1m1_ctsn &uart1m1_rtsn>; +};