fix typo
[openwrt.git] / root / etc / nvram.overrides
1 # NVRAM overrides
2 # This file handles the NVRAM quirks of various hardware
3
4 # linksys bug has lan doing dhcp; force static
5 lan_proto="static"
6
7 # failsafe if reset is held
8 [ "$FAILSAFE" = "true" ] && {
9 echo "### FAILSAFE MODE ####"
10 lan_ifname="br0"
11 lan_ifnames="vlan0 vlan2 eth1 eth2 eth3"
12 lan_ipaddr="192.168.1.1"
13 lan_netmask="255.255.255.0"
14 lan_hwaddr="00:0B:AD:0A:DD:00"
15 wan_ifname="none"
16 wifi_ifname="none"
17 }
18
19 # hacks for 1.x hardware
20 [ "$(nvram get boardnum)" = "42" ] && \
21 [ "$(nvram get boardtype)" = "bcm94710dev" ] && {
22 debug "### 1.x hardware hack ###"
23 vlan1hwname="et0"
24 vlan2hwname="et0"
25
26 # we remap old device names to new
27 # it's recommended that you continue to
28 # use the old names to preserve backwards
29 # compatibility
30 remap () {
31 eval $1=\"$(nvram_get $1 | awk 'gsub("eth0","vlan2") gsub("eth1","vlan1")')\"
32 }
33
34 remap lan_ifname
35 remap lan_ifnames
36 remap wifi_ifname
37 remap wifi_ifnames
38 remap wan_ifname
39 remap wan_ifnames
40 remap pppoe_ifname
41 }
42
43 [ -z "$(nvram_get lan_ifname)" ] && {
44 lan_ifname="br0"
45 lan_ifnames="vlan0 vlan2 eth1 eth2 eth3"
46 }
This page took 0.054689 seconds and 5 git commands to generate.