ath79: improve support for D-Link DIR-8x9 A1 series
[openwrt/staging/ldir.git] / package / boot / uboot-envtools / files / ath79
1 #
2 # Copyright (C) 2011-2014 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 alcatel,hh40v|\
16 alfa-network,ap121f|\
17 alfa-network,ap121fe|\
18 alfa-network,n2q|\
19 alfa-network,n5q|\
20 alfa-network,pi-wifi4|\
21 alfa-network,r36a|\
22 alfa-network,tube-2hq|\
23 allnet,all-wap02860ac|\
24 araknis,an-300-ap-i-n|\
25 araknis,an-500-ap-i-ac|\
26 araknis,an-700-ap-i-ac|\
27 arduino,yun|\
28 buffalo,bhr-4grv2|\
29 devolo,magic-2-wifi|\
30 dlink,dir-859-a1|\
31 dlink,dir-869-a1|\
32 engenius,eap1200h|\
33 engenius,eap1750h|\
34 engenius,eap300-v2|\
35 engenius,eap350-v1|\
36 engenius,eap600|\
37 engenius,ecb1200|\
38 engenius,ecb1750|\
39 engenius,ecb350-v1|\
40 engenius,ecb600|\
41 engenius,enh202-v1|\
42 engenius,ens202ext-v1|\
43 engenius,enstationac-v1|\
44 engenius,ews660ap|\
45 etactica,eg200|\
46 glinet,gl-ar750s-nor|\
47 glinet,gl-ar750s-nor-nand|\
48 librerouter,librerouter-v1|\
49 netgear,ex7300|\
50 netgear,ex7300-v2|\
51 netgear,wndr4300-v2|\
52 netgear,wndr4500-v3|\
53 netgear,wnr1000-v2|\
54 netgear,wnr2000-v3|\
55 netgear,wnr2200-8m|\
56 netgear,wnr2200-16m|\
57 netgear,wnr612-v2|\
58 ocedo,koala|\
59 ocedo,raccoon|\
60 openmesh,a40|\
61 openmesh,a60|\
62 openmesh,mr600-v1|\
63 openmesh,mr600-v2|\
64 openmesh,mr900-v1|\
65 openmesh,mr900-v2|\
66 openmesh,mr1750-v1|\
67 openmesh,mr1750-v2|\
68 openmesh,om5p|\
69 openmesh,om5p-an|\
70 openmesh,om5p-ac-v1|\
71 openmesh,om5p-ac-v2|\
72 samsung,wam250|\
73 ubnt,airrouter|\
74 ubnt,bullet-m-ar7240|\
75 ubnt,bullet-m-ar7241|\
76 ubnt,nanobridge-m|\
77 ubnt,nanostation-loco-m|\
78 ubnt,nanostation-m|\
79 ubnt,picostation-m|\
80 ubnt,powerbridge-m|\
81 ubnt,rocket-m|\
82 watchguard,ap100|\
83 watchguard,ap200|\
84 watchguard,ap300|\
85 yuncore,a770|\
86 yuncore,a782|\
87 yuncore,a930|\
88 yuncore,xd3200|\
89 yuncore,xd4200|\
90 ziking,cpe46b|\
91 zyxel,nbg6616)
92 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x10000" "0x10000"
93 ;;
94 aruba,ap-105|\
95 aruba,ap-175|\
96 dongwon,dw02-412h-64m|\
97 dongwon,dw02-412h-128m|\
98 glinet,gl-ar300m-lite|\
99 glinet,gl-ar300m-nand|\
100 glinet,gl-ar300m-nor|\
101 glinet,gl-ar300m16)
102 idx="$(find_mtd_index u-boot-env)"
103 [ -n "$idx" ] && \
104 ubootenv_add_uci_config "/dev/mtd$idx" "0x0" "0x10000" "0x10000"
105 ;;
106 buffalo,wzr-hp-ag300h)
107 ubootenv_add_uci_config "/dev/mtd3" "0x0" "0x10000" "0x10000"
108 ;;
109 buffalo,wzr-hp-g300nh-rb|\
110 buffalo,wzr-hp-g300nh-s|\
111 linksys,ea4500-v3)
112 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x20000" "0x20000"
113 ;;
114 domywifi,dw33d)
115 ubootenv_add_uci_config "/dev/mtd4" "0x0" "0x10000" "0x10000"
116 ;;
117 glinet,gl-ar150)
118 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x8000" "0x10000"
119 ;;
120 netgear,wndr3700|\
121 netgear,wndr3700-v2|\
122 netgear,wndrmac-v1)
123 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x20000" "0x10000"
124 ;;
125 netgear,pgzng1|\
126 netgear,wndr3700-v4|\
127 netgear,wndr4300|\
128 netgear,wndr4300tn|\
129 netgear,wndr4300sw)
130 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x40000" "0x20000"
131 ;;
132 openmesh,om2p-v1|\
133 openmesh,om2p-v2|\
134 openmesh,om2p-v4|\
135 openmesh,om2p-hs-v1|\
136 openmesh,om2p-hs-v2|\
137 openmesh,om2p-hs-v3|\
138 openmesh,om2p-hs-v4|\
139 openmesh,om2p-lc|\
140 plasmacloud,pa300|\
141 plasmacloud,pa300e)
142 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x40000" "0x40000"
143 ;;
144 qihoo,c301)
145 ubootenv_add_uci_config "/dev/mtd9" "0x0" "0x10000" "0x10000"
146 ;;
147 ruckus,zf7025|\
148 ruckus,zf7341|\
149 ruckus,zf7351|\
150 ruckus,zf7363)
151 ubootenv_add_uci_config "/dev/mtd5" "0x0" "0x40000" "0x40000"
152 ;;
153 ruckus,zf7321|\
154 ruckus,zf7372)
155 ubootenv_add_uci_config "/dev/mtd2" "0x0" "0x40000" "0x10000"
156 ;;
157 sophos,ap15|\
158 sophos,ap55|\
159 sophos,ap55c|\
160 sophos,ap100|\
161 sophos,ap100c)
162 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x1000" "0x10000"
163 ;;
164 wallys,dr531)
165 ubootenv_add_uci_config "/dev/mtd1" "0x0" "0xf800" "0x10000"
166 ;;
167 zte,mf286|\
168 zte,mf286a|\
169 zte,mf286r)
170 ubootenv_add_uci_config "/dev/mtd7" "0x0" "0x20000" "0x10000"
171 ;;
172 esac
173
174 config_load ubootenv
175 config_foreach ubootenv_add_app_config ubootenv
176
177 exit 0