2 * Copyright (c) 2018 MediaTek Inc.
3 * Author: Ryder Lee <ryder.lee@mediatek.com>
5 * SPDX-License-Identifier: (GPL-2.0 OR MIT)
9 #include <dt-bindings/input/input.h>
10 #include <dt-bindings/gpio/gpio.h>
12 #include "mt7622.dtsi"
13 #include "mt6380.dtsi"
16 model = "Bananapi BPI-R64";
17 compatible = "bananapi,bpi-r64", "mediatek,mt7622";
24 stdout-path = "serial0:115200n8";
25 bootargs = "earlycon=uart8250,mmio32,0x11002000 swiotlb=512";
30 proc-supply = <&mt6380_vcpu_reg>;
31 sram-supply = <&mt6380_vm_reg>;
35 proc-supply = <&mt6380_vcpu_reg>;
36 sram-supply = <&mt6380_vm_reg>;
41 compatible = "gpio-keys";
46 gpios = <&pio 0 GPIO_ACTIVE_HIGH>;
51 linux,code = <KEY_WPS_BUTTON>;
52 gpios = <&pio 102 GPIO_ACTIVE_LOW>;
57 compatible = "gpio-leds";
60 label = "bpi-r64:pio:green";
61 gpios = <&pio 89 GPIO_ACTIVE_HIGH>;
62 default-state = "off";
66 label = "bpi-r64:pio:red";
67 gpios = <&pio 88 GPIO_ACTIVE_HIGH>;
68 default-state = "off";
73 reg = <0 0x40000000 0 0x40000000>;
74 device_type = "memory";
77 reg_1p8v: regulator-1p8v {
78 compatible = "regulator-fixed";
79 regulator-name = "fixed-1.8V";
80 regulator-min-microvolt = <1800000>;
81 regulator-max-microvolt = <1800000>;
85 reg_3p3v: regulator-3p3v {
86 compatible = "regulator-fixed";
87 regulator-name = "fixed-3.3V";
88 regulator-min-microvolt = <3300000>;
89 regulator-max-microvolt = <3300000>;
94 reg_5v: regulator-5v {
95 compatible = "regulator-fixed";
96 regulator-name = "fixed-5V";
97 regulator-min-microvolt = <5000000>;
98 regulator-max-microvolt = <5000000>;
113 pinctrl-names = "default";
114 pinctrl-0 = <&irrx_pins>;
121 compatible = "mediatek,eth-mac";
123 phy-mode = "2500base-x";
133 compatible = "mediatek,eth-mac";
145 #address-cells = <1>;
151 pinctrl-names = "default";
152 pinctrl-0 = <&i2c1_pins>;
157 pinctrl-names = "default";
158 pinctrl-0 = <&i2c2_pins>;
163 pinctrl-names = "default", "state_uhs";
164 pinctrl-0 = <&emmc_pins_default>;
165 pinctrl-1 = <&emmc_pins_uhs>;
168 max-frequency = <50000000>;
171 vmmc-supply = <®_3p3v>;
172 vqmmc-supply = <®_1p8v>;
173 assigned-clocks = <&topckgen CLK_TOP_MSDC30_0_SEL>;
174 assigned-clock-parents = <&topckgen CLK_TOP_UNIV48M>;
179 pinctrl-names = "default", "state_uhs";
180 pinctrl-0 = <&sd0_pins_default>;
181 pinctrl-1 = <&sd0_pins_uhs>;
184 max-frequency = <50000000>;
187 cd-gpios = <&pio 81 GPIO_ACTIVE_LOW>;
188 vmmc-supply = <®_3p3v>;
189 vqmmc-supply = <®_3p3v>;
190 assigned-clocks = <&topckgen CLK_TOP_MSDC30_1_SEL>;
191 assigned-clock-parents = <&topckgen CLK_TOP_UNIV48M>;
195 pinctrl-names = "default";
196 pinctrl-0 = <¶llel_nand_pins>;
201 pinctrl-names = "default";
202 pinctrl-0 = <&spi_nor_pins>;
206 compatible = "jedec,spi-nor";
212 pinctrl-names = "default";
213 pinctrl-0 = <&pcie0_pins>, <&pcie1_pins>;
226 /* Attention: GPIO 90 is used to switch between PCIe@1,0 and
227 * SATA functions. i.e. output-high: PCIe, output-low: SATA
231 gpios = <90 GPIO_ACTIVE_HIGH>;
235 /* eMMC is shared pin with parallel NAND */
236 emmc_pins_default: emmc-pins-default {
238 function = "emmc", "emmc_rst";
242 /* "NDL0","NDL1","NDL2","NDL3","NDL4","NDL5","NDL6","NDL7",
243 * "NRB","NCLE" pins are used as DAT0,DAT1,DAT2,DAT3,DAT4,
244 * DAT5,DAT6,DAT7,CMD,CLK for eMMC respectively
247 pins = "NDL0", "NDL1", "NDL2",
248 "NDL3", "NDL4", "NDL5",
249 "NDL6", "NDL7", "NRB";
260 emmc_pins_uhs: emmc-pins-uhs {
267 pins = "NDL0", "NDL1", "NDL2",
268 "NDL3", "NDL4", "NDL5",
269 "NDL6", "NDL7", "NRB";
271 drive-strength = <4>;
277 drive-strength = <4>;
285 groups = "mdc_mdio", "rgmii_via_gmac2";
289 i2c1_pins: i2c1-pins {
296 i2c2_pins: i2c2-pins {
303 i2s1_pins: i2s1-pins {
306 groups = "i2s_out_mclk_bclk_ws",
312 pins = "I2S1_IN", "I2S1_OUT", "I2S_BCLK",
313 "I2S_WS", "I2S_MCLK";
314 drive-strength = <12>;
319 irrx_pins: irrx-pins {
326 irtx_pins: irtx-pins {
333 /* Parallel nand is shared pin with eMMC */
334 parallel_nand_pins: parallel-nand-pins {
341 pcie0_pins: pcie0-pins {
344 groups = "pcie0_pad_perst",
350 pcie1_pins: pcie1-pins {
353 groups = "pcie1_pad_perst",
359 pmic_bus_pins: pmic-bus-pins {
366 pwm7_pins: pwm1-2-pins {
369 groups = "pwm_ch7_2";
373 wled_pins: wled-pins {
380 sd0_pins_default: sd0-pins-default {
386 /* "I2S2_OUT, "I2S4_IN"", "I2S3_IN", "I2S2_IN",
387 * "I2S4_OUT", "I2S3_OUT" are used as DAT0, DAT1,
388 * DAT2, DAT3, CMD, CLK for SD respectively.
391 pins = "I2S2_OUT", "I2S4_IN", "I2S3_IN",
392 "I2S2_IN","I2S4_OUT";
394 drive-strength = <8>;
399 drive-strength = <12>;
408 sd0_pins_uhs: sd0-pins-uhs {
415 pins = "I2S2_OUT", "I2S4_IN", "I2S3_IN",
416 "I2S2_IN","I2S4_OUT";
427 /* Serial NAND is shared pin with SPI-NOR */
428 serial_nand_pins: serial-nand-pins {
435 spic0_pins: spic0-pins {
442 spic1_pins: spic1-pins {
449 /* SPI-NOR is shared pin with serial NAND */
450 spi_nor_pins: spi-nor-pins {
457 /* serial NAND is shared pin with SPI-NOR */
458 serial_nand_pins: serial-nand-pins {
465 uart0_pins: uart0-pins {
468 groups = "uart0_0_tx_rx" ;
472 uart2_pins: uart2-pins {
475 groups = "uart2_1_tx_rx" ;
479 watchdog_pins: watchdog-pins {
481 function = "watchdog";
488 pinctrl-names = "default";
489 pinctrl-0 = <&pwm7_pins>;
494 pinctrl-names = "default";
495 pinctrl-0 = <&pmic_bus_pins>;
509 pinctrl-names = "default";
510 pinctrl-0 = <&spic0_pins>;
515 pinctrl-names = "default";
516 pinctrl-0 = <&spic1_pins>;
521 vusb33-supply = <®_3p3v>;
522 vbus-supply = <®_5v>;
531 pinctrl-names = "default";
532 pinctrl-0 = <&uart0_pins>;
537 pinctrl-names = "default";
538 pinctrl-0 = <&uart2_pins>;
543 pinctrl-names = "default";
544 pinctrl-0 = <&watchdog_pins>;