/* * Copyright (c) 2016 ARM Ltd. * Copyright (c) 2016-2017, Theobroma Systems Design und Consulting GmbH * * This file is dual-licensed: you can use it either under the terms * of the GPL or the X11 license, at your option. Note that this dual * licensing only applies to this file, and not this project as a * whole. * * a) This library is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of the * License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * Or, alternatively, * * b) Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation * files (the "Software"), to deal in the Software without * restriction, including without limitation the rights to use, * copy, modify, merge, publish, distribute, sublicense, and/or * sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following * conditions: * * The above copyright notice and this permission notice shall be * included in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. */ /dts-v1/; #include "sun50i-a64.dtsi" #include / { model = "Theobroma Systems A64-uQ7 (Lynx)"; compatible = "tsd,lynx", "allwinner,sun50i-a64"; aliases { serial0 = &uart0; ethernet0 = &emac; spi0 = &spi0; spi1 = &spi1; i2c0 = &i2c0; i2c1 = &i2c1; i2c2 = &i2c2; i2c5 = &r_i2c; }; soc { reg_vcc3v3: vcc3v3 { compatible = "regulator-fixed"; regulator-name = "vcc3v3"; regulator-min-microvolt = <3300000>; regulator-max-microvolt = <3300000>; }; }; chosen { stdout-path = "serial0:115200n8"; }; /* There is a model with 2GB of DRAM, but U-Boot fixes this for us. */ memory: memory@40000000 { reg = <0x40000000 0x40000000>; }; config { u-boot,boot-led = "lynx:orange:power"; }; leds { compatible = "gpio-leds"; pinctrl-names = "default"; pinctrl-0 = <&led_pins_power>, <&led_pins_sdio>; sdio { label = "lynx:blue:sdio"; gpios = <&pio 7 10 GPIO_ACTIVE_HIGH>; }; power { label = "lynx:orange:power"; // This is bank zero in the CPUS pin controller gpios = <&r_pio 0 11 GPIO_ACTIVE_HIGH>; }; }; }; &pio { led_pins_sdio: led-pins-sdio { allwinner,pins = "PH10"; allwinner,function = "gpio_out"; allwinner,drive = ; allwinner,pull = ; }; ethphy_reset_pin: ethphy-reset-pin { allwinner,pins = "PD24"; allwinner,function = "gpio_out"; drive-strength = < 20 >; bias-disable; }; spi1_cs_pins: spi1-cs-pins { allwinner,pins = "PD4"; allwinner,function = "gpio_out"; drive-strength = < 20 >; bias-disable; }; i2c2_lynx_pins: i2c2-lynx-pins { allwinner,pins = "PE14", "PE15"; allwinner,function = "i2c2"; drive-strength = < 10 >; bias-pull-up; }; }; &r_pio { led_pins_power: led-pins-power { allwinner,pins = "PL11"; allwinner,function = "gpio_out"; allwinner,drive = ; allwinner,pull = ; }; }; &mmc0 { pinctrl-names = "default"; pinctrl-0 = <&mmc0_pins>, <&mmc0_default_cd_pin>; vmmc-supply = <®_vcc3v3>; cd-gpios = <&pio 5 6 GPIO_ACTIVE_HIGH>; cd-inverted; status = "okay"; }; &mmc2 { pinctrl-names = "default"; pinctrl-0 = <&mmc2_8bit_pins>; vmmc-supply = <®_vcc3v3>; power-gpios = <&pio 2 16 GPIO_ACTIVE_HIGH>; bus-width = <8>; non-removable; status = "okay"; }; &emac { pinctrl-names = "default"; pinctrl-0 = <&rgmii_pins>, <ðphy_reset_pin>; phy-mode = "rgmii"; phy = <&phy1>; status = "okay"; snps,reset-gpio = <&pio 3 24 GPIO_ACTIVE_LOW>; snps,reset-active-low; snps,reset-delays-us = <0 10000 30000>; rxc-skew-ps = <1800>; txc-skew-ps = <1800>; phy1: ethernet-phy@1 { reg = <6>; }; }; /* &usb_otg { dr_mode = "gadget"; status = "okay"; }; */ &uart0 { pinctrl-names = "default"; pinctrl-0 = <&uart0_pins_a>; status = "okay"; }; &i2c0 { pinctrl-names = "default"; pinctrl-0 = <&i2c0_pins>; status = "okay"; }; &i2c1 { pinctrl-names = "default"; pinctrl-0 = <&i2c1_pins>; status = "okay"; }; &i2c2 { pinctrl-names = "default"; pinctrl-0 = <&i2c2_lynx_pins>; status = "okay"; }; &r_i2c { pinctrl-names = "default"; pinctrl-0 = <&r_i2c_pins>; status = "okay"; }; &usbphy { status = "okay"; }; &ohci1 { /* EHCI1 connects to on-module USB 2.0 hubs (which takes care * of transaction translation for us), so we don't need OHCI1. */ status = "disabled"; }; &ehci1 { enable-gpios = <&pio 6 9 GPIO_ACTIVE_HIGH>, <&pio 4 4 GPIO_ACTIVE_HIGH>; status = "okay"; }; &spi0 { pinctrl-names = "default"; pinctrl-0 = <&spi0_pins>; spi-deactivate-delay = <10>; status = "okay"; #address-cells = <1>; #size-cells = <0>; w25q80bl: w25q80bl@0 { compatible = "spi-flash"; reg = <0>; spi-max-frequency = <100000000>; spi-rx-bus-width = <2>; spi-cpol; spi-cpha; }; }; &spi1 { pinctrl-names = "default"; pinctrl-0 = <&spi1_pins>, <&spi1_cs_pins>; num-cs = <2>; cs-gpios = <0>, <&pio 3 4 GPIO_ACTIVE_LOW>; status = "okay"; #address-cells = <1>; #size-cells = <0>; };