1/* 2 * Copyright (c) 2017 BayLibre, SAS. 3 * Author: Neil Armstrong <narmstrong@baylibre.com> 4 * Author: Jerome Brunet <jbrunet@baylibre.com> 5 * 6 * SPDX-License-Identifier: (GPL-2.0+ OR MIT) 7 */ 8 9/dts-v1/; 10 11#include <dt-bindings/input/input.h> 12 13#include "meson-gxl-s905x.dtsi" 14 15/ { 16 compatible = "libretech,cc", "amlogic,s905x", "amlogic,meson-gxl"; 17 model = "Libre Technology CC"; 18 19 aliases { 20 serial0 = &uart_AO; 21 }; 22 23 chosen { 24 stdout-path = "serial0:115200n8"; 25 }; 26 27 cvbs-connector { 28 compatible = "composite-video-connector"; 29 30 port { 31 cvbs_connector_in: endpoint { 32 remote-endpoint = <&cvbs_vdac_out>; 33 }; 34 }; 35 }; 36 37 emmc_pwrseq: emmc-pwrseq { 38 compatible = "mmc-pwrseq-emmc"; 39 reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>; 40 }; 41 42 hdmi-connector { 43 compatible = "hdmi-connector"; 44 type = "a"; 45 46 port { 47 hdmi_connector_in: endpoint { 48 remote-endpoint = <&hdmi_tx_tmds_out>; 49 }; 50 }; 51 }; 52 53 leds { 54 compatible = "gpio-leds"; 55 56 system { 57 label = "librecomputer:system-status"; 58 gpios = <&gpio GPIODV_24 GPIO_ACTIVE_HIGH>; 59 default-state = "on"; 60 panic-indicator; 61 }; 62 63 blue { 64 label = "librecomputer:blue"; 65 gpios = <&gpio_ao GPIOAO_2 GPIO_ACTIVE_HIGH>; 66 linux,default-trigger = "heartbeat"; 67 }; 68 }; 69 70 memory@0 { 71 device_type = "memory"; 72 reg = <0x0 0x0 0x0 0x80000000>; 73 }; 74 75 vcc_3v3: regulator-vcc_3v3 { 76 compatible = "regulator-fixed"; 77 regulator-name = "VCC_3V3"; 78 regulator-min-microvolt = <3300000>; 79 regulator-max-microvolt = <3300000>; 80 }; 81 82 vcc_card: regulator-vcc-card { 83 compatible = "regulator-gpio"; 84 85 regulator-name = "VCC_CARD"; 86 regulator-min-microvolt = <1800000>; 87 regulator-max-microvolt = <3300000>; 88 89 gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_HIGH>; 90 gpios-states = <0>; 91 92 states = <3300000 0>, 93 <1800000 1>; 94 95 regulator-settling-time-up-us = <200>; 96 regulator-settling-time-down-us = <50000>; 97 }; 98 99 vddio_boot: regulator-vddio_boot { 100 compatible = "regulator-fixed"; 101 regulator-name = "VDDIO_BOOT"; 102 regulator-min-microvolt = <3300000>; 103 regulator-max-microvolt = <3300000>; 104 }; 105}; 106 107&cec_AO { 108 status = "okay"; 109 pinctrl-0 = <&ao_cec_pins>; 110 pinctrl-names = "default"; 111 hdmi-phandle = <&hdmi_tx>; 112}; 113 114&cvbs_vdac_port { 115 cvbs_vdac_out: endpoint { 116 remote-endpoint = <&cvbs_connector_in>; 117 }; 118}; 119 120ðmac { 121 status = "okay"; 122}; 123 124&ir { 125 status = "okay"; 126 pinctrl-0 = <&remote_input_ao_pins>; 127 pinctrl-names = "default"; 128}; 129 130&hdmi_tx { 131 status = "okay"; 132 pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i2c_pins>; 133 pinctrl-names = "default"; 134}; 135 136&hdmi_tx_tmds_port { 137 hdmi_tx_tmds_out: endpoint { 138 remote-endpoint = <&hdmi_connector_in>; 139 }; 140}; 141 142&pinctrl_aobus { 143 gpio-line-names = "UART TX", 144 "UART RX", 145 "Blue LED", 146 "SDCard Voltage Switch", 147 "7J1 Header Pin5", 148 "7J1 Header Pin3", 149 "7J1 Header Pin12", 150 "IR In", 151 "9J3 Switch HDMI CEC/7J1 Header Pin11", 152 "7J1 Header Pin13"; 153}; 154 155&pinctrl_periphs { 156 gpio-line-names = /* Bank GPIOZ */ 157 "", "", "", "", "", "", "", 158 "", "", "", "", "", "", "", 159 "Eth Link LED", "Eth Activity LED", 160 /* Bank GPIOH */ 161 "HDMI HPD", "HDMI SDA", "HDMI SCL", 162 "HDMI_5V_EN", "9J1 Header Pin2", 163 "Analog Audio Mute", 164 "2J3 Header Pin6", 165 "2J3 Header Pin5", 166 "2J3 Header Pin4", 167 "2J3 Header Pin3", 168 /* Bank BOOT */ 169 "eMMC D0", "eMMC D1", "eMMC D2", "eMMC D3", 170 "eMMC D4", "eMMC D5", "eMMC D6", "eMMC D7", 171 "eMMC Clk", "eMMC Reset", "eMMC CMD", 172 "ALT BOOT MODE", "", "", "", "eMMC Data Strobe", 173 /* Bank CARD */ 174 "SDCard D1", "SDCard D0", "SDCard CLK", "SDCard CMD", 175 "SDCard D3", "SDCard D2", "SDCard Det", 176 /* Bank GPIODV */ 177 "", "", "", "", "", "", "", "", "", "", "", "", 178 "", "", "", "", "", "", "", "", "", "", "", "", 179 "Green LED", "VCCK Enable", 180 "7J1 Header Pin27", "7J1 Header Pin28", 181 "VCCK Regulator", "VDDEE Regulator", 182 /* Bank GPIOX */ 183 "7J1 Header Pin22", "7J1 Header Pin26", 184 "7J1 Header Pin36", "7J1 Header Pin38", 185 "7J1 Header Pin40", "7J1 Header Pin37", 186 "7J1 Header Pin33", "7J1 Header Pin35", 187 "7J1 Header Pin19", "7J1 Header Pin21", 188 "7J1 Header Pin24", "7J1 Header Pin23", 189 "7J1 Header Pin8", "7J1 Header Pin10", 190 "7J1 Header Pin16", "7J1 Header Pin18", 191 "7J1 Header Pin32", "7J1 Header Pin29", 192 "7J1 Header Pin31", 193 /* Bank GPIOCLK */ 194 "7J1 Header Pin7", "", 195 /* GPIO_TEST_N */ 196 "7J1 Header Pin15"; 197}; 198 199/* SD card */ 200&sd_emmc_b { 201 status = "okay"; 202 pinctrl-0 = <&sdcard_pins>; 203 pinctrl-1 = <&sdcard_clk_gate_pins>; 204 pinctrl-names = "default", "clk-gate"; 205 206 bus-width = <4>; 207 cap-sd-highspeed; 208 max-frequency = <100000000>; 209 disable-wp; 210 211 cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_HIGH>; 212 cd-inverted; 213 214 vmmc-supply = <&vcc_3v3>; 215 vqmmc-supply = <&vcc_card>; 216}; 217 218/* eMMC */ 219&sd_emmc_c { 220 status = "okay"; 221 pinctrl-0 = <&emmc_pins>; 222 pinctrl-1 = <&emmc_clk_gate_pins>; 223 pinctrl-names = "default", "clk-gate"; 224 225 bus-width = <8>; 226 cap-mmc-highspeed; 227 max-frequency = <50000000>; 228 non-removable; 229 disable-wp; 230 231 mmc-pwrseq = <&emmc_pwrseq>; 232 vmmc-supply = <&vcc_3v3>; 233 vqmmc-supply = <&vddio_boot>; 234}; 235 236&uart_AO { 237 status = "okay"; 238 pinctrl-0 = <&uart_ao_a_pins>; 239 pinctrl-names = "default"; 240}; 241