Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // SPDX-License-Identifier: GPL-2.0
- /dts-v1/;
- #include <dt-bindings/input/input.h>
- #include <dt-bindings/leds/common.h>
- #include "mt7629.dtsi"
- / {
- compatible = "asus,rt-ac67p", "mediatek,mt7629";
- model = "ASUS RT-AC67P";
- aliases {
- led-boot = &led_cpu;
- led-failsafe = &led_cpu;
- led-running = &led_cpu;
- led-upgrade = &led_cpu;
- serial0 = &uart0;
- };
- chosen {
- stdout-path = "serial0:115200n1";
- bootargs-override = "console=ttyS0,115200n1";
- };
- memory@40000000 {
- device_type = "memory";
- reg = <0x40000000 0x10000000>;
- };
- reg_3p3v: regulator-3p3v {
- compatible = "regulator-fixed";
- regulator-name = "fixed-3.3V";
- regulator-min-microvolt = <3300000>;
- regulator-max-microvolt = <3300000>;
- regulator-boot-on;
- regulator-always-on;
- };
- reg_5v: regulator-5v {
- compatible = "regulator-fixed";
- regulator-name = "fixed-5V";
- regulator-min-microvolt = <5000000>;
- regulator-max-microvolt = <5000000>;
- regulator-boot-on;
- regulator-always-on;
- };
- };
- ð {
- pinctrl-names = "default";
- pinctrl-0 = <ð_pins>;
- pinctrl-1 = <&ephy_leds_pins>;
- status = "okay";
- gmac0: mac@0 {
- compatible = "mediatek,eth-mac";
- reg = <0>;
- phy-mode = "2500base-x";
- nvmem-cells = <&macaddr_factory_4 3>;
- nvmem-cell-names = "mac-address";
- fixed-link {
- speed = <2500>;
- full-duplex;
- pause;
- };
- };
- gmac1: mac@1 {
- compatible = "mediatek,eth-mac";
- reg = <1>;
- phy-mode = "gmii";
- phy-handle = <&phy0>;
- nvmem-cells = <&macaddr_factory_4 1>;
- nvmem-cell-names = "mac-address";
- };
- mdio: mdio-bus {
- #address-cells = <1>;
- #size-cells = <0>;
- phy0: ethernet-phy@0 {
- reg = <0>;
- };
- switch@1f {
- compatible = "mediatek,mt7531";
- reg = <31>;
- reset-gpios = <&pio 28 GPIO_ACTIVE_HIGH>;
- interrupt-controller;
- #interrupt-cells = <1>;
- interrupt-parent = <&pio>;
- interrupts = <6 IRQ_TYPE_LEVEL_HIGH>;
- ports {
- #address-cells = <1>;
- #size-cells = <0>;
- port@0 {
- reg = <0>;
- label = "lan1";
- };
- port@1 {
- reg = <1>;
- label = "lan2";
- };
- port@2 {
- reg = <2>;
- label = "lan3";
- };
- port@3 {
- reg = <3>;
- label = "lan4";
- };
- port@4 {
- reg = <4>;
- label = "wan";
- };
- port@6 {
- reg = <6>;
- ethernet = <&gmac0>;
- phy-mode = "2500base-x";
- fixed-link {
- speed = <2500>;
- full-duplex;
- pause;
- };
- };
- };
- };
- };
- };
- &bch {
- status = "okay";
- };
- &snfi {
- pinctrl-names = "default";
- pinctrl-0 = <&serial_nand_pins>;
- status = "okay";
- spi_nand_flash: flash@0 {
- compatible = "u-boot-dont-touch-spi-nand";
- #address-cells = <1>;
- #size-cells = <1>;
- reg = <0>;
- spi-max-frequency = <52000000>;
- spi-tx-bus-width = <4>;
- spi-rx-bus-width = <4>;
- /*
- * ASUS bootloader tries to replace the partitions defined in
- * Device Tree and by that also deletes all additional properties
- * needed for UBI and NVMEM-on-UBI.
- * Prevent this from happening by tricking the loader to delete and
- * replace a bait node instead (works with older bootloaders).
- */
- partitions: dummy {
- compatible = "u-boot-dummy-partitions";
- #address-cells = <1>;
- #size-cells = <1>;
- partition@0 {
- reg = <0x0 0x0>;
- label = "remove_me";
- };
- };
- partitions {
- compatible = "fixed-partitions";
- #address-cells = <1>;
- #size-cells = <1>;
- partition@0 {
- label = "Bootloader";
- reg = <0x0 0xe0000>;
- read-only;
- };
- partition@e0000 {
- label = "Config";
- reg = <0xe0000 0x100000>;
- };
- partition@1e0000 {
- label = "factory";
- reg = <0x1e0000 0x100000>;
- read-only;
- nvmem-layout {
- compatible = "fixed-layout";
- #address-cells = <1>;
- #size-cells = <1>;
- macaddr_factory_4: macaddr@4 {
- compatible = "mac-base";
- reg = <0x4 0x6>;
- #nvmem-cell-cells = <1>;
- };
- };
- };
- partition@2e0000 {
- label = "Factory2";
- reg = <0x2e0000 0x100000>;
- read-only;
- };
- partition@3e0000 {
- label = "firmware";
- reg = <0x3e0000 0x3200000>;
- compatible = "fixed-partitions";
- #address-cells = <1>;
- #size-cells = <1>;
- partition@0 {
- label = "kernel";
- reg = <0x0 0x400000>;
- };
- partition@400000 {
- label = "ubi";
- reg = <0x400000 0x2e00000>;
- };
- };
- partition@35e0000 {
- label = "firmware2";
- reg = <0x35e0000 0x3200000>;
- };
- partition@67e0000 {
- label = "jffs2";
- reg = <0x67e0000 0x1020000>;
- };
- };
- };
- };
- &pio {
- eth_pins: eth-pins {
- mux {
- function = "eth";
- groups = "mdc_mdio";
- };
- };
- ephy_leds_pins: ephy-leds-pins {
- mux {
- function = "led";
- groups = "ephy_leds";
- };
- };
- /* Serial NAND is shared pin with SPI-NOR */
- serial_nand_pins: serial-nand-pins {
- mux {
- function = "flash";
- groups = "snfi";
- };
- };
- uart0_pins: uart0-pins {
- mux {
- function = "uart";
- groups = "uart0_txd_rxd" ;
- };
- };
- watchdog_pins: watchdog-pins {
- mux {
- function = "watchdog";
- groups = "watchdog";
- };
- };
- };
- &ssusb {
- vusb33-supply = <®_3p3v>;
- vbus-supply = <®_5v>;
- status = "okay";
- };
- &uart0 {
- pinctrl-names = "default";
- pinctrl-0 = <&uart0_pins>;
- status = "okay";
- };
- &watchdog {
- pinctrl-names = "default";
- pinctrl-0 = <&watchdog_pins>;
- status = "okay";
- interrupt-controller;
- #interrupt-cells = <1>;
- interrupt-parent = <&pio>;
- interrupts = <GIC_SPI 0x80 IRQ_TYPE_EDGE_FALLING>;
- };
Advertisement
Add Comment
Please, Sign In to add comment