X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=target%2Flinux%2Fath79%2Fgeneric%2Fbase-files%2Flib%2Fpreinit%2F10_fix_eth_mac.sh;h=bf40efe72b69a0e998f014d85700fb02b9d8cc4f;hb=e085812a7d7022c4bec948280efbcba738101636;hp=c2c79133420deaee6ed4b673e73eb267c845f58c;hpb=dc4745da7a3900b5dcd9158d1b83c2cda1d1b9b8;p=openwrt%2Fopenwrt.git diff --git a/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh b/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh index c2c7913342..bf40efe72b 100644 --- a/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh +++ b/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh @@ -1,4 +1,4 @@ -. /lib/functions.sh +. /lib/functions/system.sh preinit_set_mac_address() { case $(board_name) in @@ -15,9 +15,17 @@ preinit_set_mac_address() { enterasys,ws-ap3705i) ip link set dev eth0 address $(mtd_get_mac_ascii u-boot-env0 ethaddr) ;; + extreme-networks,ws-ap3805i|\ siemens,ws-ap3610) ip link set dev eth0 address $(mtd_get_mac_ascii cfg1 ethaddr) ;; + fortinet,fap-221-b) + ip link set dev eth0 address $(mtd_get_mac_text u-boot 0x3ff80 12) + ;; + tplink,deco-s4-v2) + base_mac=$(mtd_get_mac_encrypted_deco $(find_mtd_part config)) + ip link set dev eth0 address $base_mac + ;; zyxel,nbg6616) ethaddr=$(mtd_get_mac_ascii u-boot-env ethaddr) ip link set dev eth0 address $(macaddr_add $ethaddr 2)