ea8334f27f30cc56352e03238ea9956b37c9fed6
[openwrt.git] / target / linux / ar71xx / base-files / lib / ar71xx.sh
1 #!/bin/sh
2 #
3 # Copyright (C) 2009 OpenWrt.org
4 #
5
6 ar71xx_board_name() {
7 local machine
8 local name
9
10 machine=$(awk 'BEGIN{FS="[ \t]+:[ \t]"} /machine/ {print $2}' /proc/cpuinfo)
11
12 case "$machine" in
13 *ALL0258N)
14 name="all0258n"
15 ;;
16 *AP121)
17 name="ap121"
18 ;;
19 *AP121-MINI)
20 name="ap121-mini"
21 ;;
22 *AP81)
23 name="ap81"
24 ;;
25 *AP83)
26 name="ap83"
27 ;;
28 *AP96)
29 name="ap96"
30 ;;
31 *AW-NR580)
32 name="aw-nr580"
33 ;;
34 *"DIR-600 rev. A1")
35 name="dir-600-a1"
36 ;;
37 *"DIR-825 rev. B1")
38 name="dir-825-b1"
39 ;;
40 *EAP7660D)
41 name="eap7660d"
42 ;;
43 *JA76PF)
44 name="ja76pf"
45 ;;
46 *"Bullet M")
47 name="bullet-m"
48 ;;
49 *"Nanostation M")
50 name="nanostation-m"
51 ;;
52 *JWAP003)
53 name="jwap003"
54 ;;
55 *LS-SR71)
56 name="ls-sr71"
57 ;;
58 *MZK-W04NU)
59 name="mzk-w04nu"
60 ;;
61 *MZK-W300NH)
62 name="mzk-w300nh"
63 ;;
64 *"NBG460N/550N/550NH")
65 name="nbg460n_550n_550nh"
66 ;;
67 *PB42)
68 name="pb42"
69 ;;
70 *PB44)
71 name="pb44"
72 ;;
73 *PB92)
74 name="pb92"
75 ;;
76 *"RouterBOARD 411/A/AH")
77 name="rb-411"
78 ;;
79 *"RouterBOARD 411U")
80 name="rb-411u"
81 ;;
82 *"RouterBOARD 433/AH")
83 name="rb-433"
84 ;;
85 *"RouterBOARD 433UAH")
86 name="rb-433u"
87 ;;
88 *"RouterBOARD 450")
89 name="rb-450"
90 ;;
91 *"RouterBOARD 450G")
92 name="rb-450g"
93 ;;
94 *"RouterBOARD 493/AH")
95 name="rb-493"
96 ;;
97 *"RouterBOARD 493G")
98 name="rb-493g"
99 ;;
100 *"RouterBOARD 750")
101 name="rb-750"
102 ;;
103 *"Rocket M")
104 name="rocket-m"
105 ;;
106 *RouterStation)
107 name="routerstation"
108 ;;
109 *"RouterStation Pro")
110 name="routerstation-pro"
111 ;;
112 *TEW-632BRP)
113 name="tew-632brp"
114 ;;
115 *TL-WR1043ND)
116 name="tl-wr1043nd"
117 ;;
118 *"DIR-615 rev. C1")
119 name="dir-615-c1"
120 ;;
121 *TL-MR3220)
122 name="tl-mr3220"
123 ;;
124 *TL-MR3420)
125 name="tl-mr3420"
126 ;;
127 *TL-WA901ND)
128 name="tl-wa901nd"
129 ;;
130 *"TL-WA901ND v2")
131 name="tl-wa901nd-v2"
132 ;;
133 *TL-WR741ND)
134 name="tl-wr741nd"
135 ;;
136 *"TL-WR841N v1")
137 name="tl-wr841n-v1"
138 ;;
139 *TL-WR941ND)
140 name="tl-wr941nd"
141 ;;
142 *"TL-WR703N v1")
143 name="tl-wr703n"
144 ;;
145 *UniFi)
146 name="unifi"
147 ;;
148 *WP543)
149 name="wp543"
150 ;;
151 *WNDR3700)
152 name="wndr3700"
153 ;;
154 *WNDR3700v2)
155 name="wndr3700v2"
156 ;;
157 *WNR2000)
158 name="wnr2000"
159 ;;
160 *WRT160NL)
161 name="wrt160nl"
162 ;;
163 *WRT400N)
164 name="wrt400n"
165 ;;
166 *WZR-HP-AG300H)
167 name="wzr-hp-ag300h"
168 ;;
169 *WZR-HP-G300NH)
170 name="wzr-hp-g300nh"
171 ;;
172 *WHR-HP-G300N)
173 name="whr-hp-g300n"
174 ;;
175 *ZCN-1523H-2)
176 name="zcn-1523h-2"
177 ;;
178 *ZCN-1523H-5)
179 name="zcn-1523h-5"
180 ;;
181 *)
182 name="generic"
183 ;;
184 esac
185
186 echo $name
187 }
This page took 0.045118 seconds and 3 git commands to generate.