-/dts-v1/;
-
#include "mt7621.dtsi"
#include <dt-bindings/gpio/gpio.h>
label-mac-device = &gmac0;
};
- chosen {
- bootargs = "console=ttyS0,57600";
- };
-
leds {
compatible = "gpio-leds";
led_power: power {
- label = "wr1201:green:power";
+ label = "green:power";
gpios = <&gpio 24 GPIO_ACTIVE_LOW>;
};
usb {
- label = "wr1201:green:usb";
+ label = "green:usb";
gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
trigger-sources = <&xhci_ehci_port1>, <&ehci_port2>;
linux,default-trigger = "usbport";
};
eth_link {
- label = "wr1201:green:eth_link";
+ label = "green:eth_link";
gpios = <&gpio 26 GPIO_ACTIVE_LOW>;
};
wps {
- label = "wr1201:green:wps";
+ label = "green:wps";
gpios = <&gpio 23 GPIO_ACTIVE_LOW>;
};
};
};
};
+ðernet {
+ pinctrl-0 = <&mdio_pins>, <&rgmii1_pins>;
+};
+
&gmac0 {
- mtd-mac-address = <&factory 0x4>;
+ nvmem-cells = <&macaddr_factory_4>;
+ nvmem-cell-names = "mac-address";
};
&switch0 {
ports {
port@0 {
status = "okay";
- label = "lan1";
+ label = "lan4";
};
port@1 {
status = "okay";
- label = "lan2";
+ label = "lan3";
};
port@2 {
status = "okay";
- label = "lan3";
+ label = "lan2";
};
port@3 {
status = "okay";
- label = "lan4";
+ label = "lan1";
};
port@4 {
status = "okay";
label = "wan";
- mtd-mac-address = <&factory 0x4>;
- mtd-mac-address-increment = <1>;
+ nvmem-cells = <&macaddr_factory_4>;
+ nvmem-cell-names = "mac-address";
+ mac-address-increment = <1>;
};
};
};
function = "gpio";
};
};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_4: macaddr@4 {
+ reg = <0x4 0x6>;
+ };
+};