ramips: mt7620: tidy up 02_network
authorSungbo Eo <mans0n@gorani.run>
Thu, 16 Dec 2021 13:14:48 +0000 (22:14 +0900)
committerSungbo Eo <mans0n@gorani.run>
Thu, 16 Dec 2021 13:28:58 +0000 (22:28 +0900)
* fix alphabetic sorting
* consolidate duplicate cases

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
target/linux/ramips/mt7620/base-files/etc/board.d/02_network

index 2d9191176645c08b501f67153f60a71160246ccc..a00f168672f8fd7eb235d962ae6831b7014d7309 100644 (file)
@@ -90,15 +90,15 @@ ramips_setup_interfaces()
                ucidef_add_switch "switch0" \
                        "1:lan" "2:lan" "3:lan" "4:lan" "0:wan" "6@eth0"
                ;;
+       buffalo,whr-1166d)
+               ucidef_add_switch "switch0" \
+                       "0:lan" "1:lan" "2:lan" "3:lan" "5:wan" "6@eth0"
+               ;;
        buffalo,whr-300hp2|\
        buffalo,whr-600d)
                ucidef_add_switch "switch0" \
                        "0:lan:1" "1:lan:2" "2:lan:3" "3:lan:4" "4:wan:5" "6@eth0"
                ;;
-       buffalo,whr-1166d)
-               ucidef_add_switch "switch0" \
-                       "0:lan" "1:lan" "2:lan" "3:lan" "5:wan" "6@eth0"
-               ;;
        comfast,cf-wr800n|\
        hnet,c108)
                ucidef_add_switch "switch0" \
@@ -146,7 +146,8 @@ ramips_setup_interfaces()
                        "5:lan" "6@eth0"
                ucidef_add_switch_attr "switch1" "enable" "false"
                ;;
-       fon,fon2601)
+       fon,fon2601|\
+       vonets,var11n-300)
                ucidef_add_switch "switch0" \
                        "0:lan" "4:wan" "6@eth0"
                ;;
@@ -205,8 +206,8 @@ ramips_setup_interfaces()
                ucidef_add_switch "switch0" \
                        "0:lan:3" "1:lan:2" "2:lan:1" "3:wan" "6@eth0"
                ;;
-       tplink,archer-c20i|\
        tplink,archer-c20-v1|\
+       tplink,archer-c20i|\
        tplink,archer-c50-v1)
                ucidef_add_switch "switch0" \
                        "1:lan:3" "2:lan:4" "3:lan:1" "4:lan:2" "0:wan" "6@eth0"
@@ -216,10 +217,6 @@ ramips_setup_interfaces()
                        "0:lan" "1:lan" "2:lan" "3:lan" "6t@eth0"
                ucidef_set_interface_wan "usb0"
                ;;
-       vonets,var11n-300)
-               ucidef_add_switch "switch0" \
-                       "0:lan" "4:wan" "6@eth0"
-               ;;
        wavlink,wl-wn579x3)
                ucidef_add_switch "switch0" \
                        "5:lan" "4:wan" "6@eth0"
@@ -341,6 +338,7 @@ ramips_setup_macs()
                wan_mac=$(macaddr_add "$(mtd_get_mac_binary u-boot 0x1fc20)" 2)
                ;;
        lb-link,bl-w1200|\
+       netis,wf2770|\
        phicomm,k2-v22.4|\
        phicomm,k2-v22.5|\
        phicomm,k2g|\
@@ -359,10 +357,6 @@ ramips_setup_macs()
        linksys,e1700)
                wan_mac=$(mtd_get_mac_ascii config WAN_MAC_ADDR)
                ;;
-       netis,wf2770)
-               wan_mac=$(mtd_get_mac_binary factory 0x2e)
-               label_mac=$wan_mac
-               ;;
        tplink,archer-c2-v1|\
        tplink,archer-c20-v1|\
        tplink,archer-c20i|\