// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
-/dts-v1/;
#include "mt7621.dtsi"
led-failsafe = &led_wps;
led-running = &led_wps;
led-upgrade = &led_wps;
- };
-
- chosen {
- bootargs = "console=ttyS0,57600";
+ label-mac-device = &wan;
};
leds {
compatible = "gpio-leds";
usb3 {
- label = "jhr-ac876m:blue:usb3";
+ label = "blue:usb3";
gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
trigger-sources = <&xhci_ehci_port1>;
linux,default-trigger = "usbport";
};
usb2 {
- label = "jhr-ac876m:blue:usb2";
+ label = "blue:usb2";
gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
trigger-sources = <&ehci_port2>;
linux,default-trigger = "usbport";
};
led_wps: wps {
- label = "jhr-ac876m:blue:wps";
+ label = "blue:wps";
gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
};
};
};
};
-ðernet {
- mtd-mac-address = <&factory 0xe000>;
+&gmac0 {
+ nvmem-cells = <&macaddr_factory_e000>;
+ nvmem-cell-names = "mac-address";
+};
+
+&switch0 {
+ ports {
+ port@0 {
+ status = "okay";
+ label = "lan1";
+ };
+
+ port@1 {
+ status = "okay";
+ label = "lan2";
+ };
+
+ port@2 {
+ status = "okay";
+ label = "lan3";
+ };
+
+ port@3 {
+ status = "okay";
+ label = "lan4";
+ };
+ wan: port@4 {
+ status = "okay";
+ label = "wan";
+ nvmem-cells = <&macaddr_factory_4>;
+ nvmem-cell-names = "mac-address";
+ };
+ };
};
&state_default {
gpio {
- ralink,group = "i2c", "uart3", "jtag", "wdt";
- ralink,function = "gpio";
+ groups = "i2c", "uart3", "jtag", "wdt";
+ function = "gpio";
+ };
+};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_4: macaddr@4 {
+ reg = <0x4 0x6>;
+ };
+
+ macaddr_factory_e000: macaddr@e000 {
+ reg = <0xe000 0x6>;
};
};