xref: /linux/arch/arm64/boot/dts/amlogic/meson-gxl.dtsi (revision 1cf3df8a9ca73e736404e308b099459948c1e902)
115abee8aSCarlo Caione/*
215abee8aSCarlo Caione * Copyright (c) 2016 Endless Computers, Inc.
315abee8aSCarlo Caione * Author: Carlo Caione <carlo@endlessm.com>
415abee8aSCarlo Caione *
515abee8aSCarlo Caione * This file is dual-licensed: you can use it either under the terms
615abee8aSCarlo Caione * of the GPL or the X11 license, at your option. Note that this dual
715abee8aSCarlo Caione * licensing only applies to this file, and not this project as a
815abee8aSCarlo Caione * whole.
915abee8aSCarlo Caione *
1015abee8aSCarlo Caione *  a) This library is free software; you can redistribute it and/or
1115abee8aSCarlo Caione *     modify it under the terms of the GNU General Public License as
1215abee8aSCarlo Caione *     published by the Free Software Foundation; either version 2 of the
1315abee8aSCarlo Caione *     License, or (at your option) any later version.
1415abee8aSCarlo Caione *
1515abee8aSCarlo Caione *     This library is distributed in the hope that it will be useful,
1615abee8aSCarlo Caione *     but WITHOUT ANY WARRANTY; without even the implied warranty of
1715abee8aSCarlo Caione *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1815abee8aSCarlo Caione *     GNU General Public License for more details.
1915abee8aSCarlo Caione *
2015abee8aSCarlo Caione * Or, alternatively,
2115abee8aSCarlo Caione *
2215abee8aSCarlo Caione *  b) Permission is hereby granted, free of charge, to any person
2315abee8aSCarlo Caione *     obtaining a copy of this software and associated documentation
2415abee8aSCarlo Caione *     files (the "Software"), to deal in the Software without
2515abee8aSCarlo Caione *     restriction, including without limitation the rights to use,
2615abee8aSCarlo Caione *     copy, modify, merge, publish, distribute, sublicense, and/or
2715abee8aSCarlo Caione *     sell copies of the Software, and to permit persons to whom the
2815abee8aSCarlo Caione *     Software is furnished to do so, subject to the following
2915abee8aSCarlo Caione *     conditions:
3015abee8aSCarlo Caione *
3115abee8aSCarlo Caione *     The above copyright notice and this permission notice shall be
3215abee8aSCarlo Caione *     included in all copies or substantial portions of the Software.
3315abee8aSCarlo Caione *
3415abee8aSCarlo Caione *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
3515abee8aSCarlo Caione *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
3615abee8aSCarlo Caione *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
3715abee8aSCarlo Caione *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
3815abee8aSCarlo Caione *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
3915abee8aSCarlo Caione *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
4015abee8aSCarlo Caione *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
4115abee8aSCarlo Caione *     OTHER DEALINGS IN THE SOFTWARE.
4215abee8aSCarlo Caione */
4315abee8aSCarlo Caione
4415abee8aSCarlo Caione#include "meson-gx.dtsi"
45973fbd55SNeil Armstrong#include <dt-bindings/clock/gxbb-clkc.h>
46*1cf3df8aSKevin Hilman#include <dt-bindings/gpio/meson-gxl-gpio.h>
4715abee8aSCarlo Caione
4815abee8aSCarlo Caione/ {
4915abee8aSCarlo Caione	compatible = "amlogic,meson-gxl";
5015abee8aSCarlo Caione};
51fb0fe922SNeil Armstrong
52e9e27c64SNeil Armstrong&ethmac {
53e9e27c64SNeil Armstrong	reg = <0x0 0xc9410000 0x0 0x10000
54e9e27c64SNeil Armstrong	       0x0 0xc8834540 0x0 0x4>;
55e9e27c64SNeil Armstrong
56e9e27c64SNeil Armstrong	clocks = <&clkc CLKID_ETH>,
57e9e27c64SNeil Armstrong		 <&clkc CLKID_FCLK_DIV2>,
58e9e27c64SNeil Armstrong		 <&clkc CLKID_MPLL2>;
59e9e27c64SNeil Armstrong	clock-names = "stmmaceth", "clkin0", "clkin1";
60e9e27c64SNeil Armstrong
61e9e27c64SNeil Armstrong	mdio0: mdio {
62e9e27c64SNeil Armstrong		#address-cells = <1>;
63e9e27c64SNeil Armstrong		#size-cells = <0>;
64e9e27c64SNeil Armstrong		compatible = "snps,dwmac-mdio";
65e9e27c64SNeil Armstrong	};
66e9e27c64SNeil Armstrong};
67e9e27c64SNeil Armstrong
68fb0fe922SNeil Armstrong&aobus {
69fb0fe922SNeil Armstrong	pinctrl_aobus: pinctrl@14 {
70fb0fe922SNeil Armstrong		compatible = "amlogic,meson-gxl-aobus-pinctrl";
71fb0fe922SNeil Armstrong		#address-cells = <2>;
72fb0fe922SNeil Armstrong		#size-cells = <2>;
73fb0fe922SNeil Armstrong		ranges;
74fb0fe922SNeil Armstrong
75fb0fe922SNeil Armstrong		gpio_ao: bank@14 {
76fb0fe922SNeil Armstrong			reg = <0x0 0x00014 0x0 0x8>,
77fb0fe922SNeil Armstrong			      <0x0 0x0002c 0x0 0x4>,
78fb0fe922SNeil Armstrong			      <0x0 0x00024 0x0 0x8>;
79fb0fe922SNeil Armstrong			reg-names = "mux", "pull", "gpio";
80fb0fe922SNeil Armstrong			gpio-controller;
81fb0fe922SNeil Armstrong			#gpio-cells = <2>;
82fb0fe922SNeil Armstrong		};
83fb0fe922SNeil Armstrong
84fb0fe922SNeil Armstrong		uart_ao_a_pins: uart_ao_a {
85fb0fe922SNeil Armstrong			mux {
86fb0fe922SNeil Armstrong				groups = "uart_tx_ao_a", "uart_rx_ao_a";
87fb0fe922SNeil Armstrong				function = "uart_ao";
88fb0fe922SNeil Armstrong			};
89fb0fe922SNeil Armstrong		};
90fb0fe922SNeil Armstrong
91fb0fe922SNeil Armstrong		remote_input_ao_pins: remote_input_ao {
92fb0fe922SNeil Armstrong			mux {
93fb0fe922SNeil Armstrong				groups = "remote_input_ao";
94fb0fe922SNeil Armstrong				function = "remote_input_ao";
95fb0fe922SNeil Armstrong			};
96fb0fe922SNeil Armstrong		};
97fb0fe922SNeil Armstrong	};
98fb0fe922SNeil Armstrong};
99fb0fe922SNeil Armstrong
100fb0fe922SNeil Armstrong&periphs {
101fb0fe922SNeil Armstrong	pinctrl_periphs: pinctrl@4b0 {
102fb0fe922SNeil Armstrong		compatible = "amlogic,meson-gxl-periphs-pinctrl";
103fb0fe922SNeil Armstrong		#address-cells = <2>;
104fb0fe922SNeil Armstrong		#size-cells = <2>;
105fb0fe922SNeil Armstrong		ranges;
106fb0fe922SNeil Armstrong
107fb0fe922SNeil Armstrong		gpio: bank@4b0 {
108fb0fe922SNeil Armstrong			reg = <0x0 0x004b0 0x0 0x28>,
109fb0fe922SNeil Armstrong			      <0x0 0x004e8 0x0 0x14>,
110fb0fe922SNeil Armstrong			      <0x0 0x00120 0x0 0x14>,
111fb0fe922SNeil Armstrong			      <0x0 0x00430 0x0 0x40>;
112fb0fe922SNeil Armstrong			reg-names = "mux", "pull", "pull-enable", "gpio";
113fb0fe922SNeil Armstrong			gpio-controller;
114fb0fe922SNeil Armstrong			#gpio-cells = <2>;
115fb0fe922SNeil Armstrong		};
116fb0fe922SNeil Armstrong
117fb0fe922SNeil Armstrong		emmc_pins: emmc {
118fb0fe922SNeil Armstrong			mux {
119fb0fe922SNeil Armstrong				groups = "emmc_nand_d07",
120fb0fe922SNeil Armstrong				       "emmc_cmd",
121fb0fe922SNeil Armstrong				       "emmc_clk",
122fb0fe922SNeil Armstrong				       "emmc_ds";
123fb0fe922SNeil Armstrong				function = "emmc";
124fb0fe922SNeil Armstrong			};
125fb0fe922SNeil Armstrong		};
126fb0fe922SNeil Armstrong
127fb0fe922SNeil Armstrong		sdcard_pins: sdcard {
128fb0fe922SNeil Armstrong			mux {
129fb0fe922SNeil Armstrong				groups = "sdcard_d0",
130fb0fe922SNeil Armstrong				       "sdcard_d1",
131fb0fe922SNeil Armstrong				       "sdcard_d2",
132fb0fe922SNeil Armstrong				       "sdcard_d3",
133fb0fe922SNeil Armstrong				       "sdcard_cmd",
134fb0fe922SNeil Armstrong				       "sdcard_clk";
135fb0fe922SNeil Armstrong				function = "sdcard";
136fb0fe922SNeil Armstrong			};
137fb0fe922SNeil Armstrong		};
138fb0fe922SNeil Armstrong
139fb0fe922SNeil Armstrong		sdio_pins: sdio {
140fb0fe922SNeil Armstrong			mux {
141fb0fe922SNeil Armstrong				groups = "sdio_d0",
142fb0fe922SNeil Armstrong				       "sdio_d1",
143fb0fe922SNeil Armstrong				       "sdio_d2",
144fb0fe922SNeil Armstrong				       "sdio_d3",
145fb0fe922SNeil Armstrong				       "sdio_cmd",
146fb0fe922SNeil Armstrong				       "sdio_clk";
147fb0fe922SNeil Armstrong				function = "sdio";
148fb0fe922SNeil Armstrong			};
149fb0fe922SNeil Armstrong		};
150fb0fe922SNeil Armstrong
151fb0fe922SNeil Armstrong		sdio_irq_pins: sdio_irq {
152fb0fe922SNeil Armstrong			mux {
153fb0fe922SNeil Armstrong				groups = "sdio_irq";
154fb0fe922SNeil Armstrong				function = "sdio";
155fb0fe922SNeil Armstrong			};
156fb0fe922SNeil Armstrong		};
157fb0fe922SNeil Armstrong
158fb0fe922SNeil Armstrong		uart_a_pins: uart_a {
159fb0fe922SNeil Armstrong			mux {
160fb0fe922SNeil Armstrong				groups = "uart_tx_a",
161fb0fe922SNeil Armstrong				       "uart_rx_a";
162fb0fe922SNeil Armstrong				function = "uart_a";
163fb0fe922SNeil Armstrong			};
164fb0fe922SNeil Armstrong		};
165fb0fe922SNeil Armstrong
166fb0fe922SNeil Armstrong		uart_b_pins: uart_b {
167fb0fe922SNeil Armstrong			mux {
168fb0fe922SNeil Armstrong				groups = "uart_tx_b",
169fb0fe922SNeil Armstrong				       "uart_rx_b";
170fb0fe922SNeil Armstrong				function = "uart_b";
171fb0fe922SNeil Armstrong			};
172fb0fe922SNeil Armstrong		};
173fb0fe922SNeil Armstrong
174fb0fe922SNeil Armstrong		uart_c_pins: uart_c {
175fb0fe922SNeil Armstrong			mux {
176fb0fe922SNeil Armstrong				groups = "uart_tx_c",
177fb0fe922SNeil Armstrong				       "uart_rx_c";
178fb0fe922SNeil Armstrong				function = "uart_c";
179fb0fe922SNeil Armstrong			};
180fb0fe922SNeil Armstrong		};
181fb0fe922SNeil Armstrong
182fb0fe922SNeil Armstrong		i2c_a_pins: i2c_a {
183fb0fe922SNeil Armstrong			mux {
184fb0fe922SNeil Armstrong				groups = "i2c_sck_a",
185fb0fe922SNeil Armstrong				     "i2c_sda_a";
186fb0fe922SNeil Armstrong				function = "i2c_a";
187fb0fe922SNeil Armstrong			};
188fb0fe922SNeil Armstrong		};
189fb0fe922SNeil Armstrong
190fb0fe922SNeil Armstrong		i2c_b_pins: i2c_b {
191fb0fe922SNeil Armstrong			mux {
192fb0fe922SNeil Armstrong				groups = "i2c_sck_b",
193fb0fe922SNeil Armstrong				      "i2c_sda_b";
194fb0fe922SNeil Armstrong				function = "i2c_b";
195fb0fe922SNeil Armstrong			};
196fb0fe922SNeil Armstrong		};
197fb0fe922SNeil Armstrong
198fb0fe922SNeil Armstrong		i2c_c_pins: i2c_c {
199fb0fe922SNeil Armstrong			mux {
200fb0fe922SNeil Armstrong				groups = "i2c_sck_c",
201fb0fe922SNeil Armstrong				      "i2c_sda_c";
202fb0fe922SNeil Armstrong				function = "i2c_c";
203fb0fe922SNeil Armstrong			};
204fb0fe922SNeil Armstrong		};
205fb0fe922SNeil Armstrong
206fb0fe922SNeil Armstrong		eth_pins: eth_c {
207fb0fe922SNeil Armstrong			mux {
208fb0fe922SNeil Armstrong				groups = "eth_mdio",
209fb0fe922SNeil Armstrong				       "eth_mdc",
210fb0fe922SNeil Armstrong				       "eth_clk_rx_clk",
211fb0fe922SNeil Armstrong				       "eth_rx_dv",
212fb0fe922SNeil Armstrong				       "eth_rxd0",
213fb0fe922SNeil Armstrong				       "eth_rxd1",
214fb0fe922SNeil Armstrong				       "eth_rxd2",
215fb0fe922SNeil Armstrong				       "eth_rxd3",
216fb0fe922SNeil Armstrong				       "eth_rgmii_tx_clk",
217fb0fe922SNeil Armstrong				       "eth_tx_en",
218fb0fe922SNeil Armstrong				       "eth_txd0",
219fb0fe922SNeil Armstrong				       "eth_txd1",
220fb0fe922SNeil Armstrong				       "eth_txd2",
221fb0fe922SNeil Armstrong				       "eth_txd3";
222fb0fe922SNeil Armstrong				function = "eth";
223fb0fe922SNeil Armstrong			};
224fb0fe922SNeil Armstrong		};
225fb0fe922SNeil Armstrong
226fb0fe922SNeil Armstrong		pwm_e_pins: pwm_e {
227fb0fe922SNeil Armstrong			mux {
228fb0fe922SNeil Armstrong				groups = "pwm_e";
229fb0fe922SNeil Armstrong				function = "pwm_e";
230fb0fe922SNeil Armstrong			};
231fb0fe922SNeil Armstrong		};
232fb0fe922SNeil Armstrong	};
233e9e27c64SNeil Armstrong
234e9e27c64SNeil Armstrong	eth-phy-mux {
235e9e27c64SNeil Armstrong		compatible = "mdio-mux-mmioreg", "mdio-mux";
236e9e27c64SNeil Armstrong		#address-cells = <1>;
237e9e27c64SNeil Armstrong		#size-cells = <0>;
238e9e27c64SNeil Armstrong		reg = <0x0 0x55c 0x0 0x4>;
239e9e27c64SNeil Armstrong		mux-mask = <0xffffffff>;
240e9e27c64SNeil Armstrong		mdio-parent-bus = <&mdio0>;
241e9e27c64SNeil Armstrong
242e9e27c64SNeil Armstrong		internal_mdio: mdio@e40908ff {
243e9e27c64SNeil Armstrong			reg = <0xe40908ff>;
244e9e27c64SNeil Armstrong			#address-cells = <1>;
245e9e27c64SNeil Armstrong			#size-cells = <0>;
246e9e27c64SNeil Armstrong
247e9e27c64SNeil Armstrong			internal_phy: ethernet-phy@8 {
248e9e27c64SNeil Armstrong				compatible = "ethernet-phy-id0181.4400", "ethernet-phy-ieee802.3-c22";
249e9e27c64SNeil Armstrong				reg = <8>;
250e9e27c64SNeil Armstrong				max-speed = <100>;
251e9e27c64SNeil Armstrong			};
252e9e27c64SNeil Armstrong		};
253e9e27c64SNeil Armstrong
254e9e27c64SNeil Armstrong		external_mdio: mdio@2009087f {
255e9e27c64SNeil Armstrong			reg = <0x2009087f>;
256e9e27c64SNeil Armstrong			#address-cells = <1>;
257e9e27c64SNeil Armstrong			#size-cells = <0>;
258e9e27c64SNeil Armstrong		};
259e9e27c64SNeil Armstrong	};
260fb0fe922SNeil Armstrong};
261973fbd55SNeil Armstrong
262973fbd55SNeil Armstrong&hiubus {
263973fbd55SNeil Armstrong	clkc: clock-controller@0 {
264973fbd55SNeil Armstrong		compatible = "amlogic,gxl-clkc", "amlogic,gxbb-clkc";
265973fbd55SNeil Armstrong		#clock-cells = <1>;
266973fbd55SNeil Armstrong		reg = <0x0 0x0 0x0 0x3db>;
267973fbd55SNeil Armstrong	};
268973fbd55SNeil Armstrong};
2695d28bb01SNeil Armstrong
2705d28bb01SNeil Armstrong&i2c_A {
2715d28bb01SNeil Armstrong	clocks = <&clkc CLKID_I2C>;
2725d28bb01SNeil Armstrong};
2735d28bb01SNeil Armstrong
2745d28bb01SNeil Armstrong&i2c_B {
2755d28bb01SNeil Armstrong	clocks = <&clkc CLKID_I2C>;
2765d28bb01SNeil Armstrong};
2775d28bb01SNeil Armstrong
2785d28bb01SNeil Armstrong&i2c_C {
2795d28bb01SNeil Armstrong	clocks = <&clkc CLKID_I2C>;
2805d28bb01SNeil Armstrong};
2816d489dc8SNeil Armstrong
2826d489dc8SNeil Armstrong&sd_emmc_a {
2836d489dc8SNeil Armstrong	clocks = <&clkc CLKID_SD_EMMC_A>,
2846d489dc8SNeil Armstrong		 <&xtal>,
2856d489dc8SNeil Armstrong		 <&clkc CLKID_FCLK_DIV2>;
2866d489dc8SNeil Armstrong	clock-names = "core", "clkin0", "clkin1";
2876d489dc8SNeil Armstrong};
2886d489dc8SNeil Armstrong
2896d489dc8SNeil Armstrong&sd_emmc_b {
2906d489dc8SNeil Armstrong	clocks = <&clkc CLKID_SD_EMMC_B>,
2916d489dc8SNeil Armstrong		 <&xtal>,
2926d489dc8SNeil Armstrong		 <&clkc CLKID_FCLK_DIV2>;
2936d489dc8SNeil Armstrong       clock-names = "core", "clkin0", "clkin1";
2946d489dc8SNeil Armstrong};
2956d489dc8SNeil Armstrong
2966d489dc8SNeil Armstrong&sd_emmc_c {
2976d489dc8SNeil Armstrong	clocks = <&clkc CLKID_SD_EMMC_C>,
2986d489dc8SNeil Armstrong		 <&xtal>,
2996d489dc8SNeil Armstrong		 <&clkc CLKID_FCLK_DIV2>;
3006d489dc8SNeil Armstrong	clock-names = "core", "clkin0", "clkin1";
3016d489dc8SNeil Armstrong};
302