ramips: add support for Edimax RG21S
[openwrt/openwrt.git] / target / linux / ramips / base-files / etc / board.d / 02_network
index 2aab2edfea0118192b468e7f77e131cf49d563db..5668c1816d724513d8d856a56c4270e2c7014185 100755 (executable)
@@ -333,6 +333,10 @@ ramips_setup_interfaces()
                ucidef_add_switch "switch0" \
                        "0:lan" "4:wan" "6@eth0"
                ;;
+       edimax,rg21s)
+               ucidef_add_switch "switch0" \
+                       "1:lan:4" "2:lan:3" "3:lan:2" "4:lan:1" "0:wan" "6@eth0"
+               ;;
        gehua,ghl-r-001)
                ucidef_add_switch "switch0" \
                        "0:lan" "1:lan" "2:lan" "4:wan" "6@eth0"
@@ -624,6 +628,10 @@ ramips_setup_macs()
        netgear,r6850)
                wan_mac=$(macaddr_add "$(cat /sys/class/net/eth0/address)" 2)
                ;;
+       edimax,rg21s)
+               lan_mac=$(mtd_get_mac_ascii u-boot-env ethaddr)
+               wan_mac=$(mtd_get_mac_ascii u-boot-env wanaddr)
+               ;;
        hiwifi,hc5661|\
        hiwifi,hc5661a|\
        hiwifi,hc5761|\