mirror of
https://github.com/cjdelisle/openwrt.git
synced 2025-10-16 16:35:51 +00:00
Use ubootenv_add_mtd function for: - Teltonika RUTC50 - Yuncore AX830 Signed-off-by: Paweł Owoc <frut3k7@gmail.com> Link: https://github.com/openwrt/openwrt/pull/19967 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
37 lines
743 B
Plaintext
37 lines
743 B
Plaintext
[ -e /etc/config/ubootenv ] && exit 0
|
|
|
|
touch /etc/config/ubootenv
|
|
|
|
. /lib/uboot-envtools.sh
|
|
. /lib/functions.sh
|
|
|
|
board=$(board_name)
|
|
|
|
case "$board" in
|
|
elecom,wrc-x3000gs2|\
|
|
iodata,wn-dax3000gr)
|
|
ubootenv_add_mtd "0:appsblenv" "0x0" "0x40000" "0x20000"
|
|
;;
|
|
glinet,gl-b3000)
|
|
ubootenv_add_mtd "0:APPSBLENV" "0x0" "0x40000" "0x20000"
|
|
;;
|
|
linksys,mr5500|\
|
|
linksys,mx2000|\
|
|
linksys,mx5500|\
|
|
linksys,spnmx56)
|
|
ubootenv_add_mtd "u_env" "0x0" "0x40000" "0x20000"
|
|
;;
|
|
xiaomi,ax6000)
|
|
ubootenv_add_mtd "0:appsblenv" "0x0" "0x10000" "0x20000"
|
|
ubootenv_add_sys_mtd "bdata" "0x0" "0x10000" "0x20000"
|
|
;;
|
|
yuncore,ax830)
|
|
ubootenv_add_mtd "0:APPSBLENV" "0x0" "0x10000" "0x10000"
|
|
;;
|
|
esac
|
|
|
|
config_load ubootenv
|
|
config_foreach ubootenv_add_app_config
|
|
|
|
exit 0
|