aliases {
label-mac-device = &gmac0;
+
led-boot = &led_power_orange;
led-failsafe = &led_power_blue;
led-running = &led_power_blue;
aliases {
label-mac-device = &wan;
+
led-boot = &led_power_orange;
led-failsafe = &led_power_blue;
led-running = &led_power_blue;
wifi@0,0 {
compatible = "mediatek,mt76";
reg = <0x0000 0 0 0 0>;
+
mediatek,mtd-eeprom = <&factory 0x0>;
+
/* 5 GHz (phy1) does not take the address from calibration data,
but setting it manually here works */
- mtd-mac-address = <&factory 0x4>;
+ nvmem-cells = <&macaddr_factory_4>;
+ nvmem-cell-names = "mac-address";
};
};
&gmac0 {
- mtd-mac-address = <&factory 0x4>;
- mtd-mac-address-increment = <(-1)>;
+ nvmem-cells = <&macaddr_factory_4>;
+ nvmem-cell-names = "mac-address";
+ mac-address-increment = <(-1)>;
};
&switch0 {
wan: port@4 {
status = "okay";
label = "wan";
- mtd-mac-address = <&factory 0x4>;
- mtd-mac-address-increment = <(-2)>;
+ nvmem-cells = <&macaddr_factory_4>;
+ nvmem-cell-names = "mac-address";
+ mac-address-increment = <(-2)>;
};
};
};
function = "gpio";
};
};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_4: macaddr@4 {
+ reg = <0x4 0x6>;
+ };
+};
model = "D-Link DIR-860L B1";
aliases {
+ label-mac-device = &gmac0;
+
led-boot = &led_power_green;
led-failsafe = &led_power_green;
led-running = &led_power_green;
led-upgrade = &led_power_green;
- label-mac-device = &gmac0;
};
leds {
/ {
compatible = "dlink,dir-867-a1", "mediatek,mt7621-soc";
model = "D-Link DIR-867 A1";
+
+ aliases {
+ label-mac-device = &gmac0;
+ };
+};
+
+&gmac0 {
+ nvmem-cells = <&macaddr_factory_e000>;
+ nvmem-cell-names = "mac-address";
+};
+
+&wan {
+ nvmem-cells = <&macaddr_factory_e006>;
+ nvmem-cell-names = "mac-address";
+};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_e000: macaddr@e000 {
+ reg = <0xe000 0x6>;
+ };
+
+ macaddr_factory_e006: macaddr@e006 {
+ reg = <0xe006 0x6>;
+ };
};
/ {
compatible = "dlink,dir-878-a1", "mediatek,mt7621-soc";
model = "D-Link DIR-878 A1";
+
+ aliases {
+ label-mac-device = &gmac0;
+ };
+};
+
+&gmac0 {
+ nvmem-cells = <&macaddr_factory_e000>;
+ nvmem-cell-names = "mac-address";
+};
+
+&wan {
+ nvmem-cells = <&macaddr_factory_e006>;
+ nvmem-cell-names = "mac-address";
+};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_e000: macaddr@e000 {
+ reg = <0xe000 0x6>;
+ };
+
+ macaddr_factory_e006: macaddr@e006 {
+ reg = <0xe006 0x6>;
+ };
};
/ {
compatible = "dlink,dir-882-a1", "mediatek,mt7621-soc";
model = "D-Link DIR-882 A1";
+
+ aliases {
+ label-mac-device = &gmac0;
+ };
};
&leds {
linux,default-trigger = "usbport";
};
};
+
+&gmac0 {
+ nvmem-cells = <&macaddr_factory_e000>;
+ nvmem-cell-names = "mac-address";
+};
+
+&wan {
+ nvmem-cells = <&macaddr_factory_e006>;
+ nvmem-cell-names = "mac-address";
+};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_e000: macaddr@e000 {
+ reg = <0xe000 0x6>;
+ };
+
+ macaddr_factory_e006: macaddr@e006 {
+ reg = <0xe006 0x6>;
+ };
+};
/ {
compatible = "dlink,dir-882-r1", "mediatek,mt7621-soc";
model = "D-Link DIR-882 R1";
+
+ aliases {
+ label-mac-device = &gmac0;
+ };
};
&leds {
linux,default-trigger = "usbport";
};
};
+
+&gmac0 {
+ nvmem-cells = <&macaddr_factory_e000>;
+ nvmem-cell-names = "mac-address";
+};
+
+&wan {
+ nvmem-cells = <&macaddr_factory_e006>;
+ nvmem-cell-names = "mac-address";
+};
+
+&factory {
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ macaddr_factory_e000: macaddr@e000 {
+ reg = <0xe000 0x6>;
+ };
+
+ macaddr_factory_e006: macaddr@e006 {
+ reg = <0xe006 0x6>;
+ };
+};
/ {
aliases {
- label-mac-device = &gmac0;
led-boot = &led_power_orange;
led-failsafe = &led_power_green;
led-running = &led_power_green;
};
};
-&gmac0 {
- mtd-mac-address = <&factory 0xe000>;
-};
-
&switch0 {
ports {
port@0 {
label = "lan1";
};
- port@4 {
+ wan: port@4 {
status = "okay";
label = "wan";
- mtd-mac-address = <&factory 0xe006>;
};
};
};