1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2 /* 2 /* 3 * Copyright (C) 2017 Chen-Yu Tsai <wens@csie.o 3 * Copyright (C) 2017 Chen-Yu Tsai <wens@csie.org> 4 */ 4 */ 5 5 6 #include <dt-bindings/gpio/gpio.h> 6 #include <dt-bindings/gpio/gpio.h> 7 #include <dt-bindings/input/input.h> 7 #include <dt-bindings/input/input.h> 8 8 9 / { 9 / { 10 aliases { 10 aliases { 11 ethernet0 = &emac; 11 ethernet0 = &emac; 12 serial0 = &uart0; 12 serial0 = &uart0; 13 }; 13 }; 14 14 15 chosen { 15 chosen { 16 stdout-path = "serial0:115200n 16 stdout-path = "serial0:115200n8"; 17 }; 17 }; 18 18 19 connector { 19 connector { 20 compatible = "hdmi-connector"; 20 compatible = "hdmi-connector"; 21 type = "a"; 21 type = "a"; 22 22 23 port { 23 port { 24 hdmi_con_in: endpoint 24 hdmi_con_in: endpoint { 25 remote-endpoin 25 remote-endpoint = <&hdmi_out_con>; 26 }; 26 }; 27 }; 27 }; 28 }; 28 }; 29 29 30 leds { 30 leds { 31 compatible = "gpio-leds"; 31 compatible = "gpio-leds"; 32 32 33 pwr_led { 33 pwr_led { 34 label = "librecomputer 34 label = "librecomputer:green:pwr"; 35 gpios = <&r_pio 0 10 G 35 gpios = <&r_pio 0 10 GPIO_ACTIVE_HIGH>; /* PL10 */ 36 default-state = "on"; 36 default-state = "on"; 37 }; 37 }; 38 38 39 status_led { 39 status_led { 40 label = "librecomputer 40 label = "librecomputer:blue:status"; 41 gpios = <&pio 0 7 GPIO 41 gpios = <&pio 0 7 GPIO_ACTIVE_HIGH>; /* PA7 */ 42 }; 42 }; 43 }; 43 }; 44 44 45 gpio-keys { 45 gpio-keys { 46 compatible = "gpio-keys"; 46 compatible = "gpio-keys"; 47 47 48 key-power { 48 key-power { 49 label = "power"; 49 label = "power"; 50 linux,code = <KEY_POWE 50 linux,code = <KEY_POWER>; 51 gpios = <&r_pio 0 2 GP 51 gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */ 52 wakeup-source; 52 wakeup-source; 53 }; 53 }; 54 }; 54 }; 55 55 56 reg_vcc1v2: vcc1v2 { 56 reg_vcc1v2: vcc1v2 { 57 compatible = "regulator-fixed" 57 compatible = "regulator-fixed"; 58 regulator-name = "vcc1v2"; 58 regulator-name = "vcc1v2"; 59 regulator-min-microvolt = <120 59 regulator-min-microvolt = <1200000>; 60 regulator-max-microvolt = <120 60 regulator-max-microvolt = <1200000>; 61 regulator-always-on; 61 regulator-always-on; 62 regulator-boot-on; 62 regulator-boot-on; 63 vin-supply = <®_vcc5v0>; 63 vin-supply = <®_vcc5v0>; 64 gpio = <&r_pio 0 8 GPIO_ACTIVE 64 gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ 65 enable-active-high; 65 enable-active-high; 66 }; 66 }; 67 67 68 reg_vcc3v3: vcc3v3 { 68 reg_vcc3v3: vcc3v3 { 69 compatible = "regulator-fixed" 69 compatible = "regulator-fixed"; 70 regulator-name = "vcc3v3"; 70 regulator-name = "vcc3v3"; 71 regulator-min-microvolt = <330 71 regulator-min-microvolt = <3300000>; 72 regulator-max-microvolt = <330 72 regulator-max-microvolt = <3300000>; 73 vin-supply = <®_vcc5v0>; 73 vin-supply = <®_vcc5v0>; 74 }; 74 }; 75 75 76 /* This represents the board's 5V inpu 76 /* This represents the board's 5V input */ 77 reg_vcc5v0: vcc5v0 { 77 reg_vcc5v0: vcc5v0 { 78 compatible = "regulator-fixed" 78 compatible = "regulator-fixed"; 79 regulator-name = "vcc5v0"; 79 regulator-name = "vcc5v0"; 80 regulator-min-microvolt = <500 80 regulator-min-microvolt = <5000000>; 81 regulator-max-microvolt = <500 81 regulator-max-microvolt = <5000000>; 82 }; 82 }; 83 83 84 reg_vcc_dram: vcc-dram { 84 reg_vcc_dram: vcc-dram { 85 compatible = "regulator-fixed" 85 compatible = "regulator-fixed"; 86 regulator-name = "vcc-dram"; 86 regulator-name = "vcc-dram"; 87 regulator-min-microvolt = <150 87 regulator-min-microvolt = <1500000>; 88 regulator-max-microvolt = <150 88 regulator-max-microvolt = <1500000>; 89 regulator-always-on; 89 regulator-always-on; 90 regulator-boot-on; 90 regulator-boot-on; 91 vin-supply = <®_vcc5v0>; 91 vin-supply = <®_vcc5v0>; 92 gpio = <&r_pio 0 9 GPIO_ACTIVE 92 gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */ 93 enable-active-high; 93 enable-active-high; 94 }; 94 }; 95 95 96 reg_vcc_io: vcc-io { 96 reg_vcc_io: vcc-io { 97 compatible = "regulator-fixed" 97 compatible = "regulator-fixed"; 98 regulator-name = "vcc-io"; 98 regulator-name = "vcc-io"; 99 regulator-min-microvolt = <330 99 regulator-min-microvolt = <3300000>; 100 regulator-max-microvolt = <330 100 regulator-max-microvolt = <3300000>; 101 regulator-always-on; 101 regulator-always-on; 102 regulator-boot-on; 102 regulator-boot-on; 103 vin-supply = <®_vcc3v3>; 103 vin-supply = <®_vcc3v3>; 104 gpio = <&r_pio 0 5 GPIO_ACTIVE 104 gpio = <&r_pio 0 5 GPIO_ACTIVE_LOW>; /* PL5 */ 105 }; 105 }; 106 106 107 reg_vdd_cpux: vdd-cpux { 107 reg_vdd_cpux: vdd-cpux { 108 compatible = "regulator-fixed" 108 compatible = "regulator-fixed"; 109 regulator-name = "vdd-cpux"; 109 regulator-name = "vdd-cpux"; 110 regulator-min-microvolt = <120 110 regulator-min-microvolt = <1200000>; 111 regulator-max-microvolt = <120 111 regulator-max-microvolt = <1200000>; 112 regulator-always-on; 112 regulator-always-on; 113 regulator-boot-on; 113 regulator-boot-on; 114 vin-supply = <®_vcc5v0>; 114 vin-supply = <®_vcc5v0>; 115 gpio = <&r_pio 0 8 GPIO_ACTIVE 115 gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ 116 enable-active-high; 116 enable-active-high; 117 }; 117 }; 118 }; 118 }; 119 119 120 &codec { 120 &codec { 121 allwinner,audio-routing = 121 allwinner,audio-routing = 122 "Line Out", "LINEOUT", 122 "Line Out", "LINEOUT", 123 "MIC1", "Mic", 123 "MIC1", "Mic", 124 "Mic", "MBIAS"; 124 "Mic", "MBIAS"; 125 status = "okay"; 125 status = "okay"; 126 }; 126 }; 127 127 128 &cpu0 { 128 &cpu0 { 129 cpu-supply = <®_vdd_cpux>; 129 cpu-supply = <®_vdd_cpux>; 130 }; 130 }; 131 131 132 &cpu1 { 132 &cpu1 { 133 cpu-supply = <®_vdd_cpux>; 133 cpu-supply = <®_vdd_cpux>; 134 }; 134 }; 135 135 136 &cpu2 { 136 &cpu2 { 137 cpu-supply = <®_vdd_cpux>; 137 cpu-supply = <®_vdd_cpux>; 138 }; 138 }; 139 139 140 &cpu3 { 140 &cpu3 { 141 cpu-supply = <®_vdd_cpux>; 141 cpu-supply = <®_vdd_cpux>; 142 }; 142 }; 143 143 144 &de { 144 &de { 145 status = "okay"; 145 status = "okay"; 146 }; 146 }; 147 147 148 &ehci0 { 148 &ehci0 { 149 status = "okay"; 149 status = "okay"; 150 }; 150 }; 151 151 152 &ehci1 { 152 &ehci1 { 153 status = "okay"; 153 status = "okay"; 154 }; 154 }; 155 155 156 &ehci2 { 156 &ehci2 { 157 status = "okay"; 157 status = "okay"; 158 }; 158 }; 159 159 160 &ehci3 { 160 &ehci3 { 161 status = "okay"; 161 status = "okay"; 162 }; 162 }; 163 163 164 &emac { 164 &emac { 165 phy-handle = <&int_mii_phy>; 165 phy-handle = <&int_mii_phy>; 166 phy-mode = "mii"; 166 phy-mode = "mii"; 167 allwinner,leds-active-low; 167 allwinner,leds-active-low; 168 status = "okay"; 168 status = "okay"; 169 }; 169 }; 170 170 171 &hdmi { 171 &hdmi { 172 status = "okay"; 172 status = "okay"; 173 }; 173 }; 174 174 175 &hdmi_out { 175 &hdmi_out { 176 hdmi_out_con: endpoint { 176 hdmi_out_con: endpoint { 177 remote-endpoint = <&hdmi_con_i 177 remote-endpoint = <&hdmi_con_in>; 178 }; 178 }; 179 }; 179 }; 180 180 181 &ir { 181 &ir { 182 pinctrl-names = "default"; 182 pinctrl-names = "default"; 183 pinctrl-0 = <&r_ir_rx_pin>; 183 pinctrl-0 = <&r_ir_rx_pin>; 184 status = "okay"; 184 status = "okay"; 185 }; 185 }; 186 186 187 &mmc0 { 187 &mmc0 { 188 vmmc-supply = <®_vcc_io>; 188 vmmc-supply = <®_vcc_io>; 189 bus-width = <4>; 189 bus-width = <4>; 190 cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; 190 cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */ 191 status = "okay"; 191 status = "okay"; 192 }; 192 }; 193 193 194 &mmc2 { 194 &mmc2 { 195 pinctrl-names = "default"; 195 pinctrl-names = "default"; 196 pinctrl-0 = <&mmc2_8bit_pins>; 196 pinctrl-0 = <&mmc2_8bit_pins>; 197 vmmc-supply = <®_vcc_io>; 197 vmmc-supply = <®_vcc_io>; 198 bus-width = <8>; 198 bus-width = <8>; 199 non-removable; 199 non-removable; 200 status = "okay"; 200 status = "okay"; 201 }; 201 }; 202 202 203 &ohci0 { 203 &ohci0 { 204 status = "okay"; 204 status = "okay"; 205 }; 205 }; 206 206 207 &ohci1 { 207 &ohci1 { 208 status = "okay"; 208 status = "okay"; 209 }; 209 }; 210 210 211 &ohci2 { 211 &ohci2 { 212 status = "okay"; 212 status = "okay"; 213 }; 213 }; 214 214 215 &ohci3 { 215 &ohci3 { 216 status = "okay"; 216 status = "okay"; 217 }; 217 }; 218 218 219 &uart0 { 219 &uart0 { 220 pinctrl-names = "default"; 220 pinctrl-names = "default"; 221 pinctrl-0 = <&uart0_pa_pins>; 221 pinctrl-0 = <&uart0_pa_pins>; 222 status = "okay"; 222 status = "okay"; 223 }; 223 }; 224 224 225 &usb_otg { 225 &usb_otg { 226 dr_mode = "host"; 226 dr_mode = "host"; 227 status = "okay"; 227 status = "okay"; 228 }; 228 }; 229 229 230 &usbphy { 230 &usbphy { 231 /* VBUS on USB ports are always on */ 231 /* VBUS on USB ports are always on */ 232 usb0_vbus-supply = <®_vcc5v0>; 232 usb0_vbus-supply = <®_vcc5v0>; 233 usb1_vbus-supply = <®_vcc5v0>; 233 usb1_vbus-supply = <®_vcc5v0>; 234 usb2_vbus-supply = <®_vcc5v0>; 234 usb2_vbus-supply = <®_vcc5v0>; 235 usb3_vbus-supply = <®_vcc5v0>; 235 usb3_vbus-supply = <®_vcc5v0>; 236 status = "okay"; 236 status = "okay"; 237 }; 237 };
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.