| .. | .. |
|---|
| 1 | | -/* |
|---|
| 2 | | - * Copyright (c) 2017 Icenowy Zheng <icenowy@aosc.xyz> |
|---|
| 3 | | - * |
|---|
| 4 | | - * Based on sun50i-a64-pine64.dts, which is: |
|---|
| 5 | | - * Copyright (c) 2016 ARM Ltd. |
|---|
| 6 | | - * |
|---|
| 7 | | - * This file is dual-licensed: you can use it either under the terms |
|---|
| 8 | | - * of the GPL or the X11 license, at your option. Note that this dual |
|---|
| 9 | | - * licensing only applies to this file, and not this project as a |
|---|
| 10 | | - * whole. |
|---|
| 11 | | - * |
|---|
| 12 | | - * a) This library is free software; you can redistribute it and/or |
|---|
| 13 | | - * modify it under the terms of the GNU General Public License as |
|---|
| 14 | | - * published by the Free Software Foundation; either version 2 of the |
|---|
| 15 | | - * License, or (at your option) any later version. |
|---|
| 16 | | - * |
|---|
| 17 | | - * This library is distributed in the hope that it will be useful, |
|---|
| 18 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 19 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 20 | | - * GNU General Public License for more details. |
|---|
| 21 | | - * |
|---|
| 22 | | - * Or, alternatively, |
|---|
| 23 | | - * |
|---|
| 24 | | - * b) Permission is hereby granted, free of charge, to any person |
|---|
| 25 | | - * obtaining a copy of this software and associated documentation |
|---|
| 26 | | - * files (the "Software"), to deal in the Software without |
|---|
| 27 | | - * restriction, including without limitation the rights to use, |
|---|
| 28 | | - * copy, modify, merge, publish, distribute, sublicense, and/or |
|---|
| 29 | | - * sell copies of the Software, and to permit persons to whom the |
|---|
| 30 | | - * Software is furnished to do so, subject to the following |
|---|
| 31 | | - * conditions: |
|---|
| 32 | | - * |
|---|
| 33 | | - * The above copyright notice and this permission notice shall be |
|---|
| 34 | | - * included in all copies or substantial portions of the Software. |
|---|
| 35 | | - * |
|---|
| 36 | | - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, |
|---|
| 37 | | - * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
|---|
| 38 | | - * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
|---|
| 39 | | - * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
|---|
| 40 | | - * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
|---|
| 41 | | - * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
|---|
| 42 | | - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
|---|
| 43 | | - * OTHER DEALINGS IN THE SOFTWARE. |
|---|
| 44 | | - */ |
|---|
| 1 | +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) |
|---|
| 2 | +// Copyright (c) 2017 Icenowy Zheng <icenowy@aosc.xyz> |
|---|
| 3 | +// Based on sun50i-a64-pine64.dts, which is: |
|---|
| 4 | +// Copyright (c) 2016 ARM Ltd. |
|---|
| 45 | 5 | |
|---|
| 46 | 6 | /dts-v1/; |
|---|
| 47 | 7 | |
|---|
| .. | .. |
|---|
| 55 | 15 | aliases { |
|---|
| 56 | 16 | ethernet0 = &emac; |
|---|
| 57 | 17 | serial0 = &uart0; |
|---|
| 18 | + serial1 = &uart1; |
|---|
| 19 | + serial2 = &uart2; |
|---|
| 20 | + serial3 = &uart3; |
|---|
| 21 | + serial4 = &uart4; |
|---|
| 58 | 22 | }; |
|---|
| 59 | 23 | |
|---|
| 60 | 24 | chosen { |
|---|
| 61 | 25 | stdout-path = "serial0:115200n8"; |
|---|
| 26 | + }; |
|---|
| 27 | + |
|---|
| 28 | + hdmi-connector { |
|---|
| 29 | + compatible = "hdmi-connector"; |
|---|
| 30 | + type = "a"; |
|---|
| 31 | + |
|---|
| 32 | + port { |
|---|
| 33 | + hdmi_con_in: endpoint { |
|---|
| 34 | + remote-endpoint = <&hdmi_out_con>; |
|---|
| 35 | + }; |
|---|
| 36 | + }; |
|---|
| 62 | 37 | }; |
|---|
| 63 | 38 | |
|---|
| 64 | 39 | reg_vcc1v8: vcc1v8 { |
|---|
| .. | .. |
|---|
| 67 | 42 | regulator-min-microvolt = <1800000>; |
|---|
| 68 | 43 | regulator-max-microvolt = <1800000>; |
|---|
| 69 | 44 | }; |
|---|
| 45 | +}; |
|---|
| 46 | + |
|---|
| 47 | +&ac_power_supply { |
|---|
| 48 | + status = "okay"; |
|---|
| 49 | +}; |
|---|
| 50 | + |
|---|
| 51 | +&battery_power_supply { |
|---|
| 52 | + status = "okay"; |
|---|
| 53 | +}; |
|---|
| 54 | + |
|---|
| 55 | +&codec { |
|---|
| 56 | + status = "okay"; |
|---|
| 57 | +}; |
|---|
| 58 | + |
|---|
| 59 | +&codec_analog { |
|---|
| 60 | + status = "okay"; |
|---|
| 61 | +}; |
|---|
| 62 | + |
|---|
| 63 | +&dai { |
|---|
| 64 | + status = "okay"; |
|---|
| 65 | +}; |
|---|
| 66 | + |
|---|
| 67 | +&de { |
|---|
| 68 | + status = "okay"; |
|---|
| 70 | 69 | }; |
|---|
| 71 | 70 | |
|---|
| 72 | 71 | &ehci0 { |
|---|
| .. | .. |
|---|
| 80 | 79 | &emac { |
|---|
| 81 | 80 | pinctrl-names = "default"; |
|---|
| 82 | 81 | pinctrl-0 = <&rgmii_pins>; |
|---|
| 83 | | - phy-mode = "rgmii"; |
|---|
| 82 | + phy-mode = "rgmii-txid"; |
|---|
| 84 | 83 | phy-handle = <&ext_rgmii_phy>; |
|---|
| 85 | 84 | phy-supply = <®_dc1sw>; |
|---|
| 86 | 85 | status = "okay"; |
|---|
| 86 | +}; |
|---|
| 87 | + |
|---|
| 88 | +&hdmi { |
|---|
| 89 | + hvcc-supply = <®_dldo1>; |
|---|
| 90 | + status = "okay"; |
|---|
| 91 | +}; |
|---|
| 92 | + |
|---|
| 93 | +&hdmi_out { |
|---|
| 94 | + hdmi_out_con: endpoint { |
|---|
| 95 | + remote-endpoint = <&hdmi_con_in>; |
|---|
| 96 | + }; |
|---|
| 87 | 97 | }; |
|---|
| 88 | 98 | |
|---|
| 89 | 99 | &mdio { |
|---|
| .. | .. |
|---|
| 144 | 154 | vcc-hdmi-supply = <®_dldo1>; |
|---|
| 145 | 155 | }; |
|---|
| 146 | 156 | |
|---|
| 157 | +&sound { |
|---|
| 158 | + simple-audio-card,aux-devs = <&codec_analog>; |
|---|
| 159 | + simple-audio-card,widgets = "Microphone", "Microphone Jack", |
|---|
| 160 | + "Headphone", "Headphone Jack"; |
|---|
| 161 | + simple-audio-card,routing = |
|---|
| 162 | + "Left DAC", "DACL", |
|---|
| 163 | + "Right DAC", "DACR", |
|---|
| 164 | + "Headphone Jack", "HP", |
|---|
| 165 | + "ADCL", "Left ADC", |
|---|
| 166 | + "ADCR", "Right ADC", |
|---|
| 167 | + "MIC2", "Microphone Jack"; |
|---|
| 168 | + status = "okay"; |
|---|
| 169 | +}; |
|---|
| 170 | + |
|---|
| 147 | 171 | &uart0 { |
|---|
| 148 | 172 | pinctrl-names = "default"; |
|---|
| 149 | | - pinctrl-0 = <&uart0_pins_a>; |
|---|
| 173 | + pinctrl-0 = <&uart0_pb_pins>; |
|---|
| 150 | 174 | status = "okay"; |
|---|
| 151 | 175 | }; |
|---|
| 152 | 176 | |
|---|
| 177 | +/* On Pi-2 connector */ |
|---|
| 178 | +&uart2 { |
|---|
| 179 | + pinctrl-names = "default"; |
|---|
| 180 | + pinctrl-0 = <&uart2_pins>; |
|---|
| 181 | + status = "disabled"; |
|---|
| 182 | +}; |
|---|
| 183 | + |
|---|
| 184 | +/* On Euler connector */ |
|---|
| 185 | +&uart3 { |
|---|
| 186 | + pinctrl-names = "default"; |
|---|
| 187 | + pinctrl-0 = <&uart3_pins>; |
|---|
| 188 | + status = "disabled"; |
|---|
| 189 | +}; |
|---|
| 190 | + |
|---|
| 191 | +/* On Euler connector, RTS/CTS optional */ |
|---|
| 192 | +&uart4 { |
|---|
| 193 | + pinctrl-names = "default"; |
|---|
| 194 | + pinctrl-0 = <&uart4_pins>; |
|---|
| 195 | + status = "disabled"; |
|---|
| 196 | +}; |
|---|
| 197 | + |
|---|
| 153 | 198 | &usb_otg { |
|---|
| 154 | 199 | dr_mode = "host"; |
|---|
| 155 | 200 | status = "okay"; |
|---|