mpc85xx: replace user space MAC with nvmem
[openwrt/staging/jow.git] / target / linux / mpc85xx / base-files / lib / preinit / 10_fix_eth_mac.sh
1 . /lib/functions.sh
2 . /lib/functions/system.sh
3
4 preinit_set_mac_address() {
5 case $(board_name) in
6 enterasys,ws-ap3715i|\
7 extreme-networks,ws-ap3825i)
8 ip link set dev eth0 address $(mtd_get_mac_ascii cfg1 ethaddr)
9 ip link set dev eth1 address $(mtd_get_mac_ascii cfg1 eth1addr)
10 ;;
11 esac
12 }
13
14 boot_hook_add preinit_main preinit_set_mac_address