1114abfe1SNeil Armstrong// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 285596034SKevin Hilman/* 385596034SKevin Hilman * Copyright (c) 2016 Andreas Färber 485596034SKevin Hilman * Copyright (c) 2016 BayLibre, Inc. 585596034SKevin Hilman * Author: Kevin Hilman <khilman@kernel.org> 685596034SKevin Hilman */ 785596034SKevin Hilman 885596034SKevin Hilman/dts-v1/; 985596034SKevin Hilman 1085596034SKevin Hilman#include "meson-gxbb.dtsi" 11f40d437fSCarlo Caione#include <dt-bindings/gpio/gpio.h> 1285596034SKevin Hilman 1385596034SKevin Hilman/ { 1485596034SKevin Hilman compatible = "hardkernel,odroid-c2", "amlogic,meson-gxbb"; 1585596034SKevin Hilman model = "Hardkernel ODROID-C2"; 1685596034SKevin Hilman 1785596034SKevin Hilman aliases { 1885596034SKevin Hilman serial0 = &uart_AO; 19059a58fcSJorge Ramirez-Ortiz ethernet0 = ðmac; 2085596034SKevin Hilman }; 2185596034SKevin Hilman 2285596034SKevin Hilman chosen { 2385596034SKevin Hilman stdout-path = "serial0:115200n8"; 2485596034SKevin Hilman }; 2585596034SKevin Hilman 2685596034SKevin Hilman memory@0 { 2785596034SKevin Hilman device_type = "memory"; 2885596034SKevin Hilman reg = <0x0 0x0 0x0 0x80000000>; 2985596034SKevin Hilman }; 30f40d437fSCarlo Caione 315a0803bdSBrian Kim usb_otg_pwr: regulator-usb-pwrs { 325a0803bdSBrian Kim compatible = "regulator-fixed"; 335a0803bdSBrian Kim 345a0803bdSBrian Kim regulator-name = "USB_OTG_PWR"; 355a0803bdSBrian Kim 365a0803bdSBrian Kim regulator-min-microvolt = <5000000>; 375a0803bdSBrian Kim regulator-max-microvolt = <5000000>; 385a0803bdSBrian Kim 395a0803bdSBrian Kim gpio = <&gpio_ao GPIOAO_5 GPIO_ACTIVE_HIGH>; 405a0803bdSBrian Kim enable-active-high; 415a0803bdSBrian Kim }; 425a0803bdSBrian Kim 43f40d437fSCarlo Caione leds { 44f40d437fSCarlo Caione compatible = "gpio-leds"; 45f40d437fSCarlo Caione blue { 46f40d437fSCarlo Caione label = "c2:blue:alive"; 47f40d437fSCarlo Caione gpios = <&gpio_ao GPIOAO_13 GPIO_ACTIVE_LOW>; 48f40d437fSCarlo Caione linux,default-trigger = "heartbeat"; 49f40d437fSCarlo Caione default-state = "off"; 50f40d437fSCarlo Caione }; 51f40d437fSCarlo Caione }; 52ef8d2ffeSKevin Hilman 53fcf19f29SAnand Moon p5v0: regulator-p5v0 { 54fcf19f29SAnand Moon compatible = "regulator-fixed"; 55fcf19f29SAnand Moon 56fcf19f29SAnand Moon regulator-name = "P5V0"; 57fcf19f29SAnand Moon regulator-min-microvolt = <5000000>; 58fcf19f29SAnand Moon regulator-max-microvolt = <5000000>; 59fcf19f29SAnand Moon regulator-always-on; 60fcf19f29SAnand Moon }; 61fcf19f29SAnand Moon 62ef8d2ffeSKevin Hilman tflash_vdd: regulator-tflash_vdd { 63ef8d2ffeSKevin Hilman /* 64ef8d2ffeSKevin Hilman * signal name from schematics: TFLASH_VDD_EN 65ef8d2ffeSKevin Hilman */ 66ef8d2ffeSKevin Hilman compatible = "regulator-fixed"; 67ef8d2ffeSKevin Hilman 68ef8d2ffeSKevin Hilman regulator-name = "TFLASH_VDD"; 69ef8d2ffeSKevin Hilman regulator-min-microvolt = <3300000>; 70ef8d2ffeSKevin Hilman regulator-max-microvolt = <3300000>; 71ef8d2ffeSKevin Hilman 72c34cd35eSNeil Armstrong gpio = <&gpio GPIOY_12 GPIO_ACTIVE_HIGH>; 73ef8d2ffeSKevin Hilman enable-active-high; 74ef8d2ffeSKevin Hilman }; 75ef8d2ffeSKevin Hilman 76ef8d2ffeSKevin Hilman tf_io: gpio-regulator-tf_io { 77ef8d2ffeSKevin Hilman compatible = "regulator-gpio"; 78ef8d2ffeSKevin Hilman 79ef8d2ffeSKevin Hilman regulator-name = "TF_IO"; 80ef8d2ffeSKevin Hilman regulator-min-microvolt = <1800000>; 81ef8d2ffeSKevin Hilman regulator-max-microvolt = <3300000>; 82ef8d2ffeSKevin Hilman 83ef8d2ffeSKevin Hilman /* 84ef8d2ffeSKevin Hilman * signal name from schematics: TF_3V3N_1V8_EN 85ef8d2ffeSKevin Hilman */ 86ef8d2ffeSKevin Hilman gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_HIGH>; 87ef8d2ffeSKevin Hilman gpios-states = <0>; 88ef8d2ffeSKevin Hilman 89f9717178SNeil Armstrong states = <3300000 0>, 90f9717178SNeil Armstrong <1800000 1>; 91ef8d2ffeSKevin Hilman }; 92ef8d2ffeSKevin Hilman 93ef8d2ffeSKevin Hilman vcc1v8: regulator-vcc1v8 { 94ef8d2ffeSKevin Hilman compatible = "regulator-fixed"; 95ef8d2ffeSKevin Hilman regulator-name = "VCC1V8"; 96ef8d2ffeSKevin Hilman regulator-min-microvolt = <1800000>; 97ef8d2ffeSKevin Hilman regulator-max-microvolt = <1800000>; 98ef8d2ffeSKevin Hilman }; 99ef8d2ffeSKevin Hilman 100ef8d2ffeSKevin Hilman vcc3v3: regulator-vcc3v3 { 101ef8d2ffeSKevin Hilman compatible = "regulator-fixed"; 102ef8d2ffeSKevin Hilman regulator-name = "VCC3V3"; 103ef8d2ffeSKevin Hilman regulator-min-microvolt = <3300000>; 104ef8d2ffeSKevin Hilman regulator-max-microvolt = <3300000>; 105ef8d2ffeSKevin Hilman }; 106ef8d2ffeSKevin Hilman 107ef8d2ffeSKevin Hilman emmc_pwrseq: emmc-pwrseq { 108ef8d2ffeSKevin Hilman compatible = "mmc-pwrseq-emmc"; 109ef8d2ffeSKevin Hilman reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>; 110ef8d2ffeSKevin Hilman }; 111fc19afa1SNeil Armstrong 112fc19afa1SNeil Armstrong hdmi-connector { 113fc19afa1SNeil Armstrong compatible = "hdmi-connector"; 114fc19afa1SNeil Armstrong type = "a"; 115fc19afa1SNeil Armstrong 116fc19afa1SNeil Armstrong port { 117fc19afa1SNeil Armstrong hdmi_connector_in: endpoint { 118fc19afa1SNeil Armstrong remote-endpoint = <&hdmi_tx_tmds_out>; 119fc19afa1SNeil Armstrong }; 120fc19afa1SNeil Armstrong }; 121fc19afa1SNeil Armstrong }; 122fc19afa1SNeil Armstrong}; 123fc19afa1SNeil Armstrong 124fc19afa1SNeil Armstrong&cec_AO { 125fc19afa1SNeil Armstrong status = "okay"; 126fc19afa1SNeil Armstrong pinctrl-0 = <&ao_cec_pins>; 127fc19afa1SNeil Armstrong pinctrl-names = "default"; 128fc19afa1SNeil Armstrong hdmi-phandle = <&hdmi_tx>; 12985596034SKevin Hilman}; 13085596034SKevin Hilman 1318c5509f0SKevin Hilmanðmac { 1328c5509f0SKevin Hilman status = "okay"; 1333be2d9cfSNeil Armstrong pinctrl-0 = <ð_rgmii_pins>; 1348c5509f0SKevin Hilman pinctrl-names = "default"; 135feb3cbeaSJerome Brunet phy-handle = <ð_phy0>; 136b6ff2721SMartin Blumenstingl phy-mode = "rgmii"; 137b6ff2721SMartin Blumenstingl 138093d23dbSMartin Blumenstingl amlogic,tx-delay-ns = <2>; 139093d23dbSMartin Blumenstingl 140feb3cbeaSJerome Brunet mdio { 141feb3cbeaSJerome Brunet compatible = "snps,dwmac-mdio"; 142feb3cbeaSJerome Brunet #address-cells = <1>; 143feb3cbeaSJerome Brunet #size-cells = <0>; 144feb3cbeaSJerome Brunet 145feb3cbeaSJerome Brunet eth_phy0: ethernet-phy@0 { 14650290cfeSMartin Blumenstingl /* Realtek RTL8211F (0x001cc916) */ 147feb3cbeaSJerome Brunet reg = <0>; 148f29cabf2SMartin Blumenstingl 149f29cabf2SMartin Blumenstingl reset-assert-us = <10000>; 150f29cabf2SMartin Blumenstingl reset-deassert-us = <30000>; 151f29cabf2SMartin Blumenstingl reset-gpios = <&gpio GPIOZ_14 GPIO_ACTIVE_LOW>; 152f29cabf2SMartin Blumenstingl 153b94d22d9SJerome Brunet interrupt-parent = <&gpio_intc>; 15450290cfeSMartin Blumenstingl /* MAC_INTR on GPIOZ_15 */ 155b94d22d9SJerome Brunet interrupts = <29 IRQ_TYPE_LEVEL_LOW>; 156feb3cbeaSJerome Brunet }; 157feb3cbeaSJerome Brunet }; 1588c5509f0SKevin Hilman}; 1598c5509f0SKevin Hilman 1603b69bdbfSAndreas Färber&gpio_ao { 1613b69bdbfSAndreas Färber /* 1623b69bdbfSAndreas Färber * WARNING: The USB Hub on the Odroid-C2 needs a reset signal 1633b69bdbfSAndreas Färber * to be turned high in order to be detected by the USB Controller 1643b69bdbfSAndreas Färber * This signal should be handled by a USB specific power sequence 1653b69bdbfSAndreas Färber * in order to reset the Hub when USB bus is powered down. 1663b69bdbfSAndreas Färber */ 1673b69bdbfSAndreas Färber usb-hub { 1683b69bdbfSAndreas Färber gpio-hog; 1693b69bdbfSAndreas Färber gpios = <GPIOAO_4 GPIO_ACTIVE_HIGH>; 1703b69bdbfSAndreas Färber output-high; 1713b69bdbfSAndreas Färber line-name = "usb-hub-reset"; 1723b69bdbfSAndreas Färber }; 1733b69bdbfSAndreas Färber}; 1743b69bdbfSAndreas Färber 175fc19afa1SNeil Armstrong&hdmi_tx { 176fc19afa1SNeil Armstrong status = "okay"; 177fc19afa1SNeil Armstrong pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i2c_pins>; 178fc19afa1SNeil Armstrong pinctrl-names = "default"; 179fc19afa1SNeil Armstrong}; 180fc19afa1SNeil Armstrong 181fc19afa1SNeil Armstrong&hdmi_tx_tmds_port { 182fc19afa1SNeil Armstrong hdmi_tx_tmds_out: endpoint { 183fc19afa1SNeil Armstrong remote-endpoint = <&hdmi_connector_in>; 184fc19afa1SNeil Armstrong }; 185fc19afa1SNeil Armstrong}; 186fc19afa1SNeil Armstrong 1873b69bdbfSAndreas Färber&i2c_A { 1883b69bdbfSAndreas Färber status = "okay"; 1893b69bdbfSAndreas Färber pinctrl-0 = <&i2c_a_pins>; 1903b69bdbfSAndreas Färber pinctrl-names = "default"; 1913b69bdbfSAndreas Färber}; 1923b69bdbfSAndreas Färber 1933b69bdbfSAndreas Färber&ir { 1943b69bdbfSAndreas Färber status = "okay"; 1953b69bdbfSAndreas Färber pinctrl-0 = <&remote_input_ao_pins>; 1963b69bdbfSAndreas Färber pinctrl-names = "default"; 1973b69bdbfSAndreas Färber}; 1983b69bdbfSAndreas Färber 1992165b006SNeil Armstrong&gpio_ao { 200b03c7d64SNeil Armstrong gpio-line-names = "UART TX", "UART RX", "VCCK En", "TF 3V3/1V8 En", 201b03c7d64SNeil Armstrong "USB HUB nRESET", "USB OTG Power En", 202b03c7d64SNeil Armstrong "J7 Header Pin2", "IR In", "J7 Header Pin4", 203b03c7d64SNeil Armstrong "J7 Header Pin6", "J7 Header Pin5", "J7 Header Pin7", 204e43f20e8SJerome Brunet "HDMI CEC", "SYS LED", 205e43f20e8SJerome Brunet /* GPIO_TEST_N */ 206e43f20e8SJerome Brunet ""; 207b03c7d64SNeil Armstrong}; 208b03c7d64SNeil Armstrong 2092165b006SNeil Armstrong&gpio { 210b03c7d64SNeil Armstrong gpio-line-names = /* Bank GPIOZ */ 211b03c7d64SNeil Armstrong "Eth MDIO", "Eth MDC", "Eth RGMII RX Clk", 212b03c7d64SNeil Armstrong "Eth RX DV", "Eth RX D0", "Eth RX D1", "Eth RX D2", 213b03c7d64SNeil Armstrong "Eth RX D3", "Eth RGMII TX Clk", "Eth TX En", 214b03c7d64SNeil Armstrong "Eth TX D0", "Eth TX D1", "Eth TX D2", "Eth TX D3", 215b03c7d64SNeil Armstrong "Eth PHY nRESET", "Eth PHY Intc", 216b03c7d64SNeil Armstrong /* Bank GPIOH */ 217b03c7d64SNeil Armstrong "HDMI HPD", "HDMI DDC SDA", "HDMI DDC SCL", "", 218b03c7d64SNeil Armstrong /* Bank BOOT */ 219b03c7d64SNeil Armstrong "eMMC D0", "eMMC D1", "eMMC D2", "eMMC D3", "eMMC D4", 220b03c7d64SNeil Armstrong "eMMC D5", "eMMC D6", "eMMC D7", "eMMC Clk", 221b03c7d64SNeil Armstrong "eMMC Reset", "eMMC CMD", 222b03c7d64SNeil Armstrong "", "", "", "", "", "", "", 223b03c7d64SNeil Armstrong /* Bank CARD */ 224b03c7d64SNeil Armstrong "SDCard D1", "SDCard D0", "SDCard CLK", "SDCard CMD", 225b03c7d64SNeil Armstrong "SDCard D3", "SDCard D2", "SDCard Det", 226b03c7d64SNeil Armstrong /* Bank GPIODV */ 227b03c7d64SNeil Armstrong "", "", "", "", "", "", "", "", "", "", "", "", "", 228b03c7d64SNeil Armstrong "", "", "", "", "", "", "", "", "", "", "", 229b03c7d64SNeil Armstrong "I2C A SDA", "I2C A SCK", "I2C B SDA", "I2C B SCK", 230b03c7d64SNeil Armstrong "PWM D", "PWM B", 231b03c7d64SNeil Armstrong /* Bank GPIOY */ 232b03c7d64SNeil Armstrong "Revision Bit0", "Revision Bit1", "", 233b03c7d64SNeil Armstrong "J2 Header Pin35", "", "", "", "J2 Header Pin36", 234b03c7d64SNeil Armstrong "J2 Header Pin31", "", "", "", "TF VDD En", 235b03c7d64SNeil Armstrong "J2 Header Pin32", "J2 Header Pin26", "", "", 236b03c7d64SNeil Armstrong /* Bank GPIOX */ 237b03c7d64SNeil Armstrong "J2 Header Pin29", "J2 Header Pin24", 238b03c7d64SNeil Armstrong "J2 Header Pin23", "J2 Header Pin22", 239b03c7d64SNeil Armstrong "J2 Header Pin21", "J2 Header Pin18", 240b03c7d64SNeil Armstrong "J2 Header Pin33", "J2 Header Pin19", 241b03c7d64SNeil Armstrong "J2 Header Pin16", "J2 Header Pin15", 242b03c7d64SNeil Armstrong "J2 Header Pin12", "J2 Header Pin13", 243b03c7d64SNeil Armstrong "J2 Header Pin8", "J2 Header Pin10", 244b03c7d64SNeil Armstrong "", "", "", "", "", 245e43f20e8SJerome Brunet "J2 Header Pin11", "", "J2 Header Pin7", "", 246b03c7d64SNeil Armstrong /* Bank GPIOCLK */ 247e43f20e8SJerome Brunet "", "", "", ""; 248b03c7d64SNeil Armstrong}; 249b03c7d64SNeil Armstrong 25062158c6aSHeiner Kallweit&saradc { 25162158c6aSHeiner Kallweit status = "okay"; 25262158c6aSHeiner Kallweit vref-supply = <&vcc1v8>; 25362158c6aSHeiner Kallweit}; 25462158c6aSHeiner Kallweit 2553b69bdbfSAndreas Färber&scpi_clocks { 2563b69bdbfSAndreas Färber status = "disabled"; 2573b69bdbfSAndreas Färber}; 2583b69bdbfSAndreas Färber 259ef8d2ffeSKevin Hilman/* SD */ 260ef8d2ffeSKevin Hilman&sd_emmc_b { 261ef8d2ffeSKevin Hilman status = "okay"; 262ef8d2ffeSKevin Hilman pinctrl-0 = <&sdcard_pins>; 26367e7607fSJerome Brunet pinctrl-1 = <&sdcard_clk_gate_pins>; 26467e7607fSJerome Brunet pinctrl-names = "default", "clk-gate"; 265ef8d2ffeSKevin Hilman 266ef8d2ffeSKevin Hilman bus-width = <4>; 267ef8d2ffeSKevin Hilman cap-sd-highspeed; 2687e2b33ffSJerome Brunet sd-uhs-sdr12; 2697e2b33ffSJerome Brunet sd-uhs-sdr25; 2707e2b33ffSJerome Brunet sd-uhs-sdr50; 2717e2b33ffSJerome Brunet sd-uhs-ddr50; 272ef8d2ffeSKevin Hilman max-frequency = <100000000>; 273ef8d2ffeSKevin Hilman disable-wp; 274ef8d2ffeSKevin Hilman 275f29200c8SLoys Ollivier cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_LOW>; 276ef8d2ffeSKevin Hilman 277ef8d2ffeSKevin Hilman vmmc-supply = <&tflash_vdd>; 278ef8d2ffeSKevin Hilman vqmmc-supply = <&tf_io>; 279ef8d2ffeSKevin Hilman}; 280ef8d2ffeSKevin Hilman 281ef8d2ffeSKevin Hilman/* eMMC */ 282ef8d2ffeSKevin Hilman&sd_emmc_c { 283ef8d2ffeSKevin Hilman status = "okay"; 284ab36be66SNeil Armstrong pinctrl-0 = <&emmc_pins>, <&emmc_ds_pins>; 28567e7607fSJerome Brunet pinctrl-1 = <&emmc_clk_gate_pins>; 28667e7607fSJerome Brunet pinctrl-names = "default", "clk-gate"; 287ef8d2ffeSKevin Hilman 288ef8d2ffeSKevin Hilman bus-width = <8>; 2897e2b33ffSJerome Brunet max-frequency = <200000000>; 290ef8d2ffeSKevin Hilman non-removable; 291ef8d2ffeSKevin Hilman disable-wp; 292ef8d2ffeSKevin Hilman cap-mmc-highspeed; 293ef8d2ffeSKevin Hilman mmc-ddr-1_8v; 294ef8d2ffeSKevin Hilman mmc-hs200-1_8v; 295ef8d2ffeSKevin Hilman 296ef8d2ffeSKevin Hilman mmc-pwrseq = <&emmc_pwrseq>; 297ef8d2ffeSKevin Hilman vmmc-supply = <&vcc3v3>; 298ef8d2ffeSKevin Hilman vqmmc-supply = <&vcc1v8>; 299ef8d2ffeSKevin Hilman}; 3003b69bdbfSAndreas Färber 3013b69bdbfSAndreas Färber&uart_AO { 3023b69bdbfSAndreas Färber status = "okay"; 3033b69bdbfSAndreas Färber pinctrl-0 = <&uart_ao_a_pins>; 3043b69bdbfSAndreas Färber pinctrl-names = "default"; 3053b69bdbfSAndreas Färber}; 3063b69bdbfSAndreas Färber 3073b69bdbfSAndreas Färber&usb0_phy { 3083b69bdbfSAndreas Färber status = "okay"; 3093b69bdbfSAndreas Färber phy-supply = <&usb_otg_pwr>; 3103b69bdbfSAndreas Färber}; 3113b69bdbfSAndreas Färber 3123b69bdbfSAndreas Färber&usb1_phy { 3133b69bdbfSAndreas Färber status = "okay"; 314e841ec95SNeil Armstrong phy-supply = <&usb_otg_pwr>; 3153b69bdbfSAndreas Färber}; 3163b69bdbfSAndreas Färber 3173b69bdbfSAndreas Färber&usb0 { 3183b69bdbfSAndreas Färber status = "okay"; 3193b69bdbfSAndreas Färber}; 3203b69bdbfSAndreas Färber 3213b69bdbfSAndreas Färber&usb1 { 3223b69bdbfSAndreas Färber status = "okay"; 3233b69bdbfSAndreas Färber}; 324