kernel: bump 5.10 to 5.10.142
[openwrt/openwrt.git] / package / boot / uboot-envtools / files / ramips
1 #
2 # Copyright (C) 2011-2012 OpenWrt.org
3 #
4
5 [ -e /etc/config/ubootenv ] && exit 0
6
7 touch /etc/config/ubootenv
8
9 . /lib/uboot-envtools.sh
10 . /lib/functions.sh
11
12 board=$(board_name)
13
14 case "$board" in
15 alfa-network,ac1200rm|\
16 alfa-network,awusfree1|\
17 alfa-network,quad-e4g|\
18 alfa-network,r36m-e4g|\
19 alfa-network,tube-e4g|\
20 engenius,esr600h|\
21 sitecom,wlr-4100-v1-002)
22 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x1000"
23 ;;
24 allnet,all0256n-4m|\
25 allnet,all0256n-8m|\
26 allnet,all5002|\
27 yuncore,ax820)
28 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x10000" "0x10000"
29 ;;
30 ampedwireless,ally-00x19k|\
31 ampedwireless,ally-r1900k)
32 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x20000" "4"
33 ;;
34 beeline,smartbox-giga|\
35 beeline,smartbox-turbo)
36 ubootenv_add_uci_config "/dev/mtd0" "0x80000" "0x1000" "0x20000"
37 ;;
38 buffalo,wsr-1166dhp|\
39 buffalo,wsr-600dhp|\
40 mediatek,linkit-smart-7688|\
41 samknows,whitebox-v8|\
42 xiaomi,mi-router-4c|\
43 xiaomi,miwifi-nano|\
44 zbtlink,zbt-wg2626|\
45 zte,mf283plus)
46 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x10000"
47 ;;
48 h3c,tx1800-plus|\
49 h3c,tx1801-plus|\
50 h3c,tx1806|\
51 jcg,q20|\
52 netgear,wax202)
53 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x20000" "0x20000"
54 ;;
55 hootoo,ht-tm05|\
56 ravpower,rp-wd03)
57 idx="$(find_mtd_index u-boot-env)"
58 [ -n "$idx" ] && \
59 ubootenv_add_uci_config "/dev/mtd$idx" "0x4000" "0x1000" "0x1000"
60 ;;
61 beeline,smartbox-flash|\
62 linksys,ea6350-v4|\
63 linksys,ea7300-v1|\
64 linksys,ea7300-v2|\
65 linksys,ea7500-v2|\
66 linksys,ea8100-v1|\
67 linksys,ea8100-v2|\
68 mts,wg430223)
69 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x20000"
70 ;;
71 xiaomi,mi-router-3g-v2|\
72 xiaomi,mi-router-4a-gigabit|\
73 xiaomi,miwifi-3c)
74 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x10000"
75 ubootenv_add_uci_sys_config "/dev/mtd2" "0x0" "0x4000" "0x10000"
76 ;;
77 xiaomi,mi-router-3g|\
78 xiaomi,mi-router-3-pro|\
79 xiaomi,mi-router-4|\
80 xiaomi,mi-router-ac2100|\
81 xiaomi,redmi-router-ac2100)
82 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x20000"
83 ubootenv_add_uci_sys_config "/dev/mtd2" "0x0" "0x4000" "0x20000"
84 ;;
85 zyxel,lte3301-plus)
86 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x80000"
87 ;;
88 zyxel,nr7101)
89 idx="$(find_mtd_index Config)"
90 [ -n "$idx" ] && \
91 ubootenv_add_uci_config "/dev/mtd$idx" "0x0" "0x1000" "0x80000"
92 ;;
93 bolt,arion|\
94 xiaomi,mi-router-cr6606|\
95 xiaomi,mi-router-cr6608|\
96 xiaomi,mi-router-cr6609)
97 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x10000" "0x20000"
98 ;;
99 esac
100
101 config_load ubootenv
102 config_foreach ubootenv_add_app_config
103
104 exit 0