mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-29 10:08:59 +00:00
19 lines
336 B
Plaintext
19 lines
336 B
Plaintext
|
#!/bin/ash
|
||
|
|
||
|
[ "$ACTION" = "add" ] || exit 0
|
||
|
|
||
|
PHYNBR=${DEVPATH##*/phy}
|
||
|
|
||
|
[ -n $PHYNBR ] || exit 0
|
||
|
|
||
|
. /lib/functions.sh
|
||
|
. /lib/functions/system.sh
|
||
|
|
||
|
board=$(board_name)
|
||
|
|
||
|
case "$board" in
|
||
|
meraki,mr26)
|
||
|
macaddr_add "$(macaddr_setbit_la $(mtd_get_mac_binary_ubi 'board-config' 0x66))" $(($PHYNBR * 8 + 1)) > /sys${DEVPATH}/macaddress
|
||
|
;;
|
||
|
esac
|