ucidef_set_interface_lan "eth0 eth1"
;;
zyxel,nbg6817)
- hw_mac_addr=$(mtd_get_mac_ascii 0:APPSBLENV ethaddr)
+ hw_mac_addr=$(mtd_get_mac_ascii 0:appsblenv ethaddr)
+ # XXX: drop upper case after kernel v5.4 is gone (qcom-smem)
+ [ -n "$hw_mac_addr" ] || \
+ hw_mac_addr=$(mtd_get_mac_ascii 0:APPSBLENV ethaddr)
ucidef_add_switch "switch0" \
"1:lan" "2:lan" "3:lan" "4:lan" "6@eth1" "5:wan" "0@eth0"
ucidef_set_interface_macaddr "lan" "$(macaddr_add $hw_mac_addr 2)"
ath10k_patch_mac $(macaddr_add $(mtd_get_mac_binary default-mac 0x0) -1)
;;
zyxel,nbg6817)
- caldata_extract "0:ART" 0x1000 0x2f20
- ath10k_patch_mac $(macaddr_add $(mtd_get_mac_ascii 0:APPSBLENV ethaddr) +1)
+ if [ -b "$(find_mtd_part 0:art)" ]; then
+ caldata_extract "0:art" 0x1000 0x2f20
+ ath10k_patch_mac $(macaddr_add $(mtd_get_mac_ascii 0:appsblenv ethaddr) +1)
+ else
+ # XXX: drop upper case after kernel v5.4 is gone (qcom-smem)
+ caldata_extract "0:ART" 0x1000 0x2f20
+ ath10k_patch_mac $(macaddr_add $(mtd_get_mac_ascii 0:APPSBLENV ethaddr) +1)
+ fi
;;
esac
;;
ath10k_patch_mac $(mtd_get_mac_binary default-mac 0x0)
;;
zyxel,nbg6817)
- caldata_extract "0:ART" 0x5000 0x2f20
- ath10k_patch_mac $(mtd_get_mac_ascii 0:APPSBLENV ethaddr)
+ if [ -b "$(find_mtd_part 0:art)" ]; then
+ caldata_extract "0:art" 0x5000 0x2f20
+ ath10k_patch_mac $(mtd_get_mac_ascii 0:appsblenv ethaddr)
+ else
+ # XXX: drop upper case after kernel v5.4 is gone (qcom-smem)
+ caldata_extract "0:ART" 0x5000 0x2f20
+ ath10k_patch_mac $(mtd_get_mac_ascii 0:APPSBLENV ethaddr)
+ fi
;;
esac
;;
[ -b "${rootfs}" ] || return 1
case "$board" in
zyxel,nbg6817)
- local dualflagmtd="$(find_mtd_part 0:DUAL_FLAG)"
+ local dualflagmtd="$(find_mtd_part 0:dual_flag)"
+ # XXX: drop upper case after kernel v5.4 is gone (qcom-smem)
+ [ -b $dualflagmtd ] || \
+ dualflagmtd="$(find_mtd_part 0:DUAL_FLAG)"
[ -b $dualflagmtd ] || return 1
case "$rootfs" in