ath79: provide label MAC address
authorAdrian Schmutzler <freifunk@adrianschmutzler.de>
Thu, 15 Aug 2019 13:13:33 +0000 (15:13 +0200)
committerPetr Štetiar <ynezz@true.cz>
Thu, 19 Sep 2019 21:43:27 +0000 (23:43 +0200)
This patch adds the label MAC address for several devices in
ath79.

Some devices require setting the MAC address in 02_network:

For the following devices, the netif device can be linked in
device tree, but the MAC address cannot be read:
- alfa-network,ap121f
- avm,fritz300e
- ubnt-xm devices

For the following devices, label MAC address is tied to lan or
wan, so no node to link to exists in device tree:
- adtran,bsap1800-v2
- adtran,bsap1840
- dlink,dir-842-c1/-c2/-c3
- engenius,ecb1750
- iodata,etg3-r
- iodata,wn-ac1167dgr
- iodata,wn-ac1600dgr
- iodata,wn-ac1600dgr2
- iodata,wn-ag300dgr
- nec,wg800hp
- nec,wg1200cr
- trendnet,tew-823dru

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
54 files changed:
target/linux/ath79/base-files/etc/board.d/02_network
target/linux/ath79/dts/ar7161_aruba_ap-105.dts
target/linux/ath79/dts/ar7161_netgear_wndr3700.dtsi
target/linux/ath79/dts/ar7240_tplink_tl-wr74xn-v1.dtsi
target/linux/ath79/dts/ar7241_tplink.dtsi
target/linux/ath79/dts/ar7241_tplink_tl-wr842n-v1.dts
target/linux/ath79/dts/ar7241_ubnt_airrouter.dts
target/linux/ath79/dts/ar7241_ubnt_unifi.dts
target/linux/ath79/dts/ar7241_ubnt_xm.dtsi
target/linux/ath79/dts/ar7241_ubnt_xm_outdoor.dtsi
target/linux/ath79/dts/ar7242_avm_fritz300e.dts
target/linux/ath79/dts/ar7242_buffalo_wzr-hp-g450h.dts
target/linux/ath79/dts/ar7242_tplink_tl-wr2543-v1.dts
target/linux/ath79/dts/ar9132_tplink_tl-wa901nd-v2.dts
target/linux/ath79/dts/ar9132_tplink_tl-wr1043nd-v1.dts
target/linux/ath79/dts/ar9132_tplink_tl-wr941-v2.dts
target/linux/ath79/dts/ar9330_glinet_gl-ar150.dts
target/linux/ath79/dts/ar9331_8dev_carambola2.dts
target/linux/ath79/dts/ar9331_pisen_ts-d084.dts
target/linux/ath79/dts/ar9331_tplink_tl-mr3020-v1.dts
target/linux/ath79/dts/ar9331_tplink_tl-mr3040-v2.dts
target/linux/ath79/dts/ar9331_tplink_tl-wr703n_tl-mr10u.dtsi
target/linux/ath79/dts/ar9331_tplink_tl-wr710n-v1.dts
target/linux/ath79/dts/ar9331_tplink_tl-wr741nd-v4.dtsi
target/linux/ath79/dts/ar9341_tplink.dtsi
target/linux/ath79/dts/ar9342_ubnt_xw.dtsi
target/linux/ath79/dts/ar9344_comfast_cf-e120a-v3.dts
target/linux/ath79/dts/ar9344_tplink_cpexxx.dtsi
target/linux/ath79/dts/ar9344_tplink_tl-wdr3500-v1.dts
target/linux/ath79/dts/ar9344_tplink_tl-wdr4300.dtsi
target/linux/ath79/dts/qca9531_comfast_cf-e5.dts
target/linux/ath79/dts/qca9531_glinet_gl-ar300m.dtsi
target/linux/ath79/dts/qca9531_glinet_gl-ar750.dts
target/linux/ath79/dts/qca9531_tplink_archer-d50-v1.dts
target/linux/ath79/dts/qca9533_tplink_cpe210.dtsi
target/linux/ath79/dts/qca9533_tplink_tl-wr841.dtsi
target/linux/ath79/dts/qca9533_tplink_tl-wr842n-v3.dts
target/linux/ath79/dts/qca9533_ubnt_acb-isp.dts
target/linux/ath79/dts/qca953x_tplink_tl-wr810n.dtsi
target/linux/ath79/dts/qca9558_netgear_ex7300.dtsi
target/linux/ath79/dts/qca9558_ocedo_koala.dts
target/linux/ath79/dts/qca9558_tplink_archer-c7.dtsi
target/linux/ath79/dts/qca9558_tplink_rex5x.dtsi
target/linux/ath79/dts/qca9558_tplink_tl-wdr4900-v2.dts
target/linux/ath79/dts/qca9558_tplink_tl-wr1043nd.dtsi
target/linux/ath79/dts/qca9558_tplink_tl-wr941n-v7-cn.dts
target/linux/ath79/dts/qca9561_tplink_archer-c25-v1.dts
target/linux/ath79/dts/qca9561_tplink_archer-c5x.dtsi
target/linux/ath79/dts/qca9563_tplink_archer-c7-v4.dts
target/linux/ath79/dts/qca9563_tplink_archer-x6-v2.dtsi
target/linux/ath79/dts/qca9563_tplink_archer-x7-v5.dtsi
target/linux/ath79/dts/qca9563_tplink_tl-wr1043n.dtsi
target/linux/ath79/dts/qca9563_ubnt_unifiac-lite.dtsi
target/linux/ath79/dts/qca9563_ubnt_unifiac-pro.dtsi

index 5b47af8ef7bcf6173db4faff6db1d83652482209..2ed4ee010cbfecb841053f855b0bfe307a8477cc 100755 (executable)
@@ -314,9 +314,19 @@ ath79_setup_macs()
        adtran,bsap1800-v2|\
        adtran,bsap1840)
                lan_mac=$(mtd_get_mac_binary "Board data" 2)
+               label_mac=$lan_mac
+               ;;
+       alfa-network,ap121f|\
+       ubnt,airrouter|\
+       ubnt,bullet-m|\
+       ubnt,nanostation-m|\
+       ubnt,rocket-m|\
+       ubnt,unifi)
+               label_mac=$(cat /sys/class/ieee80211/phy0/macaddress)
                ;;
        avm,fritz300e)
                lan_mac=$(fritz_tffs -n maca -i $(find_mtd_part "tffs (1)"))
+               label_mac=$(cat /sys/class/ieee80211/phy0/macaddress)
                ;;
        avm,fritz4020)
                lan_mac=$(fritz_tffs -n maca -i $(find_mtd_part "tffs (1)"))
@@ -334,8 +344,13 @@ ath79_setup_macs()
        dlink,dir-842-c1|\
        dlink,dir-842-c2|\
        dlink,dir-842-c3|\
+       nec,wg1200cr)
+               lan_mac=$(mtd_get_mac_ascii devdata "lanmac")
+               wan_mac=$(mtd_get_mac_ascii devdata "wanmac")
+               label_mac=$lan_mac
+               ;;
        dlink,dir-859-a1|\
-       nec,wg1200cr|\
+       qihoo,c301|\
        wd,mynet-n750)
                lan_mac=$(mtd_get_mac_ascii devdata "lanmac")
                wan_mac=$(mtd_get_mac_ascii devdata "wanmac")
@@ -346,12 +361,9 @@ ath79_setup_macs()
                ;;
        engenius,ecb1750)
                lan_mac=$(mtd_get_mac_ascii u-boot-env ethaddr)
+               label_mac=$(mtd_get_mac_ascii u-boot-env athaddr)
                ;;
-       engenius,epg5000|\
-       iodata,wn-ac1167dgr|\
-       iodata,wn-ac1600dgr|\
-       iodata,wn-ac1600dgr2|\
-       iodata,wn-ag300dgr)
+       engenius,epg5000)
                lan_mac=$(mtd_get_mac_ascii u-boot-env ethaddr)
                wan_mac=$(mtd_get_mac_ascii u-boot-env wanaddr)
                ;;
@@ -364,6 +376,15 @@ ath79_setup_macs()
        iodata,etg3-r)
                lan_mac=$(mtd_get_mac_ascii u-boot-env ethaddr)
                wan_mac=$(macaddr_add "$lan_mac" -1)
+               label_mac=$wan_mac
+               ;;
+       iodata,wn-ac1167dgr|\
+       iodata,wn-ac1600dgr|\
+       iodata,wn-ac1600dgr2|\
+       iodata,wn-ag300dgr)
+               lan_mac=$(mtd_get_mac_ascii u-boot-env ethaddr)
+               wan_mac=$(mtd_get_mac_ascii u-boot-env wanaddr)
+               label_mac=$wan_mac
                ;;
        jjplus,ja76pf2)
                wan_mac=$(fconfig -s -r -d $(find_mtd_part "RedBoot config") -n alias/ethaddr)
@@ -372,6 +393,7 @@ ath79_setup_macs()
        nec,wg800hp)
                lan_mac=$(mtd_get_mac_text board_data 0x280)
                wan_mac=$(mtd_get_mac_text board_data 0x480)
+               label_mac=$wan_mac
                ;;
        netgear,wndr3700|\
        netgear,wndr3700v2|\
@@ -382,10 +404,6 @@ ath79_setup_macs()
                lan_mac=$(k2t_get_mac "lan_mac")
                wan_mac=$(k2t_get_mac "wan_mac")
                ;;
-       qihoo,c301)
-               lan_mac=$(mtd_get_mac_ascii devdata lanmac)
-               wan_mac=$(mtd_get_mac_ascii devdata wanmac)
-               ;;
        rosinson,wr818)
                wan_mac=$(mtd_get_mac_binary factory 0x0)
                lan_mac=$(macaddr_setbit_la "$wan_mac")
@@ -406,6 +424,7 @@ ath79_setup_macs()
        trendnet,tew-823dru)
                lan_mac=$(mtd_get_mac_text mac 0x4)
                wan_mac=$(mtd_get_mac_text mac 0x18)
+               label_mac=$wan_mac
                ;;
        ubnt,routerstation|\
        ubnt,routerstation-pro)
@@ -419,6 +438,7 @@ ath79_setup_macs()
 
        [ -n "$lan_mac" ] && ucidef_set_interface_macaddr "lan" $lan_mac
        [ -n "$wan_mac" ] && ucidef_set_interface_macaddr "wan" $wan_mac
+       [ -n "$label_mac" ] && ucidef_set_label_macaddr $label_mac
 }
 
 board_config_update
index 45d4d03f314c54b092b98c12ce8800732715bda9..91f6e1dc0272cde44e03d066eff80d6ea38937ad 100644 (file)
@@ -19,6 +19,7 @@
                led-failsafe = &power_red;
                led-running = &power_green;
                led-upgrade = &power_green;
+               label-mac-device = &eth0;
        };
 
        extosc: ref {
index 89e9b2fbb7a535c1d05a0a891a2eb3e511cfa19a..070f4507788fbd4237b5f76c5537fcf1cb6efac3 100644 (file)
@@ -12,6 +12,7 @@
                led-failsafe = &power_orange;
                led-running = &power_green;
                led-upgrade = &power_orange;
+               label-mac-device = &eth0;
        };
 
        chosen {
index b7db74d937b6a90b8eb7b1fe97c090e0c673e79e..89c11762b5d05c8a25c069259230bff27b3145fa 100644 (file)
@@ -11,6 +11,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &ath9k;
        };
 
        keys {
index fa6ba71925c444fccd8561e6594ce58a1bbf3435..827c51ba8b43599701b01e16d9ffdb57bf0d2102 100644 (file)
@@ -11,6 +11,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &ath9k;
        };
 
        keys {
index 282446b1e1884bce94294c2f1aaa13fa990d1e8b..15cb22b5184a7ae0183773a5ae14fb00eabe0593 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &ath9k;
        };
 
        keys {
index 774a45f22d46bea8321449c4305907ae961d42ac..f12d4341c64a233cc3b8e1f6f9249316310fb1d0 100644 (file)
@@ -12,6 +12,7 @@
                led-failsafe = &globe;
                led-running = &globe;
                led-upgrade = &globe;
+               label-mac-device = &wifi;
        };
 
        airrouter-leds {
index 27aec88cca24c93b4f4c15838b98697e94fb7fc2..44a5fdd0bd5f2f27e4f98444b9186b07d0350496 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &dome_green;
                led-running = &dome_green;
                led-upgrade = &dome_green;
+               label-mac-device = &wifi;
        };
 
        extosc: ref {
 &pcie {
        status = "okay";
 
-       wifi@0,0 {
+       wifi: wifi@0,0 {
                reg = <0x0000 0 0 0 0>;
                qca,no-eeprom;
        };
index 546657522949d9d85bf68f10fc32a1a55cdf5bca..d330a56ee2a0376431e352022ef8889ffd300f16 100644 (file)
@@ -89,7 +89,7 @@
 &pcie {
        status = "okay";
 
-       wifi@0,0 {
+       wifi: wifi@0,0 {
                reg = <0x0000 0 0 0 0>;
                qca,no-eeprom;
        };
index c773f1aac3ca38b3ef200b9a93bda055f8336e0a..787a01771ed96a0e6a2dd9e0e1a7180586a5ebab 100644 (file)
@@ -9,6 +9,7 @@
        aliases {
                led-boot = &link4;
                led-failsafe = &link4;
+               label-mac-device = &wifi;
        };
 
        leds {
index 3621714d9d5261503166433ebfc7bb6fb7c21fb5..a7fdc977809a4585c7fe79310033b68af6f41698 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &power;
                led-running = &power;
                led-upgrade = &power;
+               label-mac-device = &ath9k;
        };
 
        keys {
index e76f677fd5d48d265d9483ffffd045f2f9455c68..37c98604adcbf629b9032ccf6ce41b0924c996dc 100644 (file)
        compatible = "buffalo,wzr-hp-g450h", "qca,ar7242";
        model = "Buffalo WZR-HP-G450H/WZR-450HP";
 
+       aliases {
+               label-mac-device = &eth0;
+       };
+
        ath9k-leds {
                compatible = "gpio-leds";
 
index c42207e6cffb2c3f20b574ace30c1a5d81929a20..08f82a871013624f892054f509d08ca2eb7cc511 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        chosen {
index 6551d0a7ff2b004deabe9b65a1cdfdf744e7bd84..2fff08195b12be2f978dbe843604f0c0dbe2f40d 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        extosc: ref {
index f617d89c5ba766ff92b79ae7e6f8628b698bb8af..88b9d36a2d6d6d2a9d3e3f295f1a235d72696484 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        extosc: ref {
index 93b99beb6d103f72eb15f5c918e1da69709dedc6..80677fa894643ff2e1ab1299973b7d9a04bdadb1 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &eth0;
        };
 
        keys {
index 76f6e8023666704b779afecdb5276255d4f88515..e4ea4c95af2e1bcbe67a8f3ffde2363a6d081564 100644 (file)
@@ -15,6 +15,7 @@
                led-boot = &wlan;
                led-failsafe = &wlan;
                led-upgrade = &wlan;
+               label-mac-device = &eth0;
        };
 
        leds {
index eb8ea3b20c9e60ef034a8393a43d99cda6f60c2b..8af378ef9296bd72e0310ca6f9d21a127808ba13 100644 (file)
@@ -12,6 +12,7 @@
 
        aliases {
                serial0 = &uart;
+               label-mac-device = &wmac;
        };
 
        leds {
index 1dc659b9e438dd6b1b3700506512f094ab89c3b6..8b8e304c9ba4493bd1977d56b1334443b9eacd2f 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &wmac;
        };
 
        keys {
index 9182374235a8b85a79cff075f85fdda9e378962e..728463bb9d480065e1a1cb4afbc291721a10aef5 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        leds {
index ebf4d4485f850eea234936862e707edb3426f08c..1644799235ec1923ef71925479d820a132709db8 100644 (file)
@@ -13,6 +13,7 @@
        aliases {
                led-boot = &led_lan;
                led-failsafe = &led_lan;
+               label-mac-device = &eth0;
        };
 
        leds {
index ffd3d71a6202ae6c273a5b991c74e0cc0e1d205c..a0f54850c1c92becefa1e092cc8a19c46ff67aec 100644 (file)
@@ -13,6 +13,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        keys {
index 056e9fa51260e1659980fd9969716a9c6759fa96..0254b40aaef71222c2721b7f201adc656302712c 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &eth0;
        };
 
        keys {
index e4b59f1591245c47cd71912622ddaf4d7a1a80eb..9fef023f80cb1b4a5f33c7a53c6c5c969937d46b 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &wmac;
        };
 
        keys {
index e4724819369493d12fd94a8211f41c88e42d91d3..5dbcac34af96cfa2e9a7c30e720389853f70145c 100644 (file)
@@ -13,6 +13,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &wmac;
        };
 
        keys: keys {
index 84fc22215667244c390a1104a46548b5c7c89e6c..76c5c5efcaf55a57bb8d2353c51efc1dec27e2cc 100644 (file)
@@ -14,6 +14,7 @@
                led-running = &system;
                led-upgrade = &system;
                led-failsafe = &system;
+               label-mac-device = &wmac;
        };
 
        leds {
index b0fdce77a61786b8d77949190de6aa0d5476896c..8fe45f64a37705ec7137ab6db8da3264141abeff 100644 (file)
@@ -15,6 +15,7 @@
                led-boot = &wan;
                led-failsafe = &wan;
                led-upgrade = &wan;
+               label-mac-device = &eth0;
        };
 
        leds {
index 15b4fc88764f1a06d560d8c7d431b5829060c41f..dc7313b58afafc22a9f62bac6977527c8f5e8a56 100644 (file)
@@ -7,6 +7,10 @@
 #include "ar9344.dtsi"
 
 / {
+       aliases {
+               label-mac-device = &wmac;
+       };
+
        keys {
                compatible = "gpio-keys";
 
index fbe10752e76abc27cd0e044b5dce03bc000d1b36..e709e6b547062ff6a79ecef6b071554206895884 100644 (file)
@@ -6,6 +6,10 @@
 / {
        model = "TP-Link TL-WDR3500 v1";
        compatible = "tplink,tl-wdr3500-v1", "qca,ar9344";
+
+       aliases {
+               label-mac-device = &wmac;
+       };
 };
 
 &leds {
index edf60df0cc927f4d718db6dda482241a34296273..9ca96cc7cd0221b9fe49050bcb8a404d71abcfed 100644 (file)
@@ -2,6 +2,12 @@
 
 #include "ar9344_tplink_tl-wdrxxxx.dtsi"
 
+/ {
+       aliases {
+               label-mac-device = &ath9k;
+       };
+};
+
 &leds {
        usb1 {
                label = "tp-link:green:usb1";
index c181b32aa6bbd4b29eefb6f4dc50b54a2bac929d..3851f77f6a300f3d32b7baad3a88af2f374d729c 100644 (file)
        compatible = "comfast,cf-e5", "qca,qca9531";
        model = "COMFAST CF-E5/E7";
 
+       aliases {
+               label-mac-device = &eth0;
+       };
+
        keys {
                compatible = "gpio-keys-polled";
                poll-interval = <20>;
index 8b127ed1d831b3c6c87b4a9991eb35d31df3a9c9..5d0dd74c3ffb1f7d08a3661d9c76fe3abebdfaf2 100644 (file)
@@ -11,6 +11,7 @@
                led-failsafe = &led_status;
                led-running = &led_status;
                led-upgrade = &led_status;
+               label-mac-device = &eth0;
        };
 
        keys {
index 54aad320f6206b1e94d72a43eae1c3ec6dc991ab..1ce0d91bfe8269a6fca9d6b4f71d6783c5a43d73 100644 (file)
        compatible = "glinet,gl-ar750", "qca,qca9531";
        model = "GL.iNet GL-AR750";
 
+       aliases {
+               label-mac-device = &eth0;
+       };
+
        keys {
                compatible = "gpio-keys";
 
index 25c1d050da914536780981b2e426605fabab3a0a..430a8f98edec3ca23eb0850d7e7e14b9533f19b1 100644 (file)
        compatible = "tplink,archer-d50-v1", "qca,qca9531";
        model = "TP-Link Archer D50 v1";
 
+       aliases {
+               label-mac-device = &wmac;
+       };
+
        chosen {
                bootargs = "console=ttyS0,115200n8";
        };
index f86ff30fc7b09d99b55a07dcf0b08f0c9640278a..f61b05d746b839a3d5906784a066e1cded94ee39 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        leds {
index 34f242ac5625f7b0d6f8a5e99aa7af3f0469a2bf..61777027ede72d8428a695a90bb143833b0f5eb6 100644 (file)
                bootargs = "console=ttyS0,115200n8";
        };
 
+       aliases {
+               label-mac-device = &wmac;
+       };
+
        gpio_leds: leds {
                compatible = "gpio-leds";
 
index 22d70af594a8975e882a43642de492d19615032f..8a6667e02880f8ab84409f24d0fd9b0bbb260c2d 100644 (file)
@@ -15,6 +15,7 @@
                led-failsafe = &power_led;
                led-running = &power_led;
                led-upgrade = &power_led;
+               label-mac-device = &eth1;
        };
 
        gpio_leds: leds {
index 3bdaa8ba9b08fd2bd351a3756a172d5ec74c12ab..590ec448e9434d7f4cac106c09df00540ea8bab1 100644 (file)
        compatible = "ubnt,acb-isp", "qca,qca9533";
        model = "Ubiquiti airCube ISP";
 
+       aliases {
+               label-mac-device = &wmac;
+       };
+
        keys {
                compatible = "gpio-keys";
 
index d4faee7506cf0f36c4ab2e81b7cd556df0690055..649e538fc03523d59d136e7c918c3dcbac62cadf 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &eth1;
        };
 
        gpio_leds: leds {
index 3e94eda95327c6cada278f0188138ac9ec88af65..2d91ba1ce1fbd97e7b1679da1e1bc7fdfa1c29da 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &power_amber;
                led-running = &power_green;
                led-upgrade = &power_amber;
+               label-mac-device = &eth0;
        };
 
        led_spi {
index a80155b08c8829a2106c4a0346cd7356d5afed00..5b5554155779522f8a2f0bb786da5a119960cfe8 100644 (file)
@@ -19,6 +19,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        leds {
index 343d318e0b49704babb0b378e67e2c6f5d3a5012..c1bd7953963fa0867fb49b401ff844a64cbe6b91 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth1;
        };
 
        gpio_leds: leds {
index c593cc434f0b904e393e5eea900aff4ce4885e28..2bc0f38f02c300f99ce36a1baf71c6d075cab2db 100644 (file)
@@ -17,6 +17,7 @@
                led-running = &led_power;
                led-upgrade = &led_power;
                mdio-gpio0 = &mdio2;
+               label-mac-device = &eth0;
        };
 
        leds {
index 3cc2d790d4a2a3f0ec24efbe8139e0ab1f3bb8e0..77166b8bfeb18b76a2f716d299538a79af8dacdc 100644 (file)
@@ -19,6 +19,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &eth1;
        };
 
        gpio_leds: leds {
index 61d4aec6243a15ff3cad94cdb8d7da15fd07f91b..1092250f02ab3504053eb062c4092b004f2d9b38 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &wmac;
        };
 
        leds {
index c33fe7404ac01b52df3455338cfdde2e98eb3cfb..13dacc2ff8d6d723a4b89ae24bdc2ac57c1a8d63 100644 (file)
@@ -19,6 +19,7 @@
                led-failsafe = &led_system;
                led-running = &led_system;
                led-upgrade = &led_system;
+               label-mac-device = &eth0;
        };
 
        leds {
index 881e3a1822531cd78aa40e1fe003f987f158887a..794ac24ed8fca5b4754837e4e6983a3420d9e229 100644 (file)
@@ -55,6 +55,7 @@
                led-failsafe = &power;
                led-running = &power;
                led-upgrade = &power;
+               label-mac-device = &eth0;
        };
 
        leds {
index 141baa6bd4ee8006707f68c587233e63d38c756c..80d8e707bbc58b574add8aca8729523ee99a7f02 100644 (file)
@@ -13,6 +13,7 @@
                led-failsafe = &power;
                led-running = &power;
                led-upgrade = &power;
+               label-mac-device = &eth1;
        };
 
        chosen {
index f4add2fe31f9c94dfc3294f3c1e66ea4a8f1e8fa..9c8e00ca907de6286426108b5c5eb183ccdfff83 100644 (file)
@@ -19,6 +19,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        led_spi {
index ac10d9134a64f4c14941e5ee24abdb7332abab5a..2ed5e0ceb408ffc07a229ca564a74c4f49dea1d3 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &power;
                led-running = &power;
                led-upgrade = &power;
+               label-mac-device = &eth0;
        };
 
        leds {
index 324d8312492a958a82f17789a5587f165d3ffe80..2e66e0f03e6270ad0c4cebb020d0fa72710a85fe 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &eth0;
        };
 
        gpio_leds: leds {
index 42b4b6b8c6746ca05aaffd66d4719d0abb5df35b..d21bee6970108f062becd0eadb656436e834a60d 100644 (file)
@@ -16,6 +16,7 @@
                led-failsafe = &system;
                led-running = &system;
                led-upgrade = &system;
+               label-mac-device = &wmac;
        };
 
        gpio_leds: leds {
index 6fe43453ec2b1e3a04bf430db0f364a86a20ccf9..4f77661fbd88be626e013d606caaaab97321a9a5 100644 (file)
@@ -2,6 +2,12 @@
 
 #include "qca9563_ubnt_unifiac.dtsi"
 
+/ {
+       aliases {
+               label-mac-device = &eth0;
+       };
+};
+
 &mdio0 {
        status = "okay";
 
index f21814355028e36325e460e41942dc09ba01fa6b..3a6c0cd3faaf67252b6c65e30c7d2c8845bee5fc 100644 (file)
@@ -2,6 +2,12 @@
 
 #include "qca9563_ubnt_unifiac.dtsi"
 
+/ {
+       aliases {
+               label-mac-device = &eth0;
+       };
+};
+
 &mdio0 {
        status = "okay";
        phy-mask = <0>;