Modify

Opened 10 years ago

Closed 10 years ago

#536 closed defect (fixed)

Default NVRAM init script needs fixing for Buffalo WLA2-G54L

Reported by: juhe Owned by: florian
Priority: normal Milestone: 0.9/rc6
Component: base system Version:
Keywords: buffalo wla2 nvram init-scripts Cc:

Description

The Buffalo WLA2-G54L has a default NVRAM configuration, which is not compatible with current RC5 init scripts. The default installation results in a non-responsive router and requires a serial cable to get into working order. See the thread "RC5: No success with Buffalo WLA2-G54L" on the General Discussion forum.

Suggested fixes:

  • Add missing product_name=$(nvram get product_name) to the beginning of /etc/init.d/S05nvram
  • Add some commands to force reasonable switch VLAN settings to the WLA2-G54L -specific section of S05nvram script, such as

/usr/sbin/nvram set vlan0ports="1 2 5t"
/usr/sbin/nvram set vlan1ports="3 4 5t"

The CFE bootloader seems to reset these to vlan0ports="1 2 3 4 5t" and vlan1ports="0 5t", which makes vlan1 completely inaccessible, as there is no physical Ethernet connector for switch port 0.

Attachments (0)

Change History (6)

comment:1 Changed 10 years ago by wbx

Hi,

can you prepare a "svn diff" against whiterussian svn branch? Tested and verified on your buffalo.

If you do not know how to create the diff, please contact me via email: wbx@…

comment:2 Changed 10 years ago by kaloz

  • Milestone set to 1.0-rc6

comment:3 Changed 10 years ago by florian

  • Owner changed from developers to florian
  • Status changed from new to assigned

comment:4 Changed 10 years ago by florian

Should be fixed in [3809]

comment:5 Changed 10 years ago by jr

Change Florian did in 3809 is incorrect and should be removed for proper operation.

Buffalo WLA2-G54L has four LAN ports and no WAN ports. That's how it's supposed to be and how device is advertised by manufacturer. If someone wants to use it as router with 3 LAN ports and 1 WAN port (or 2+2 as OpenWrt currently does) it should be hack done by end-user themself.

Because CFE forces all four ports as LAN and switches them together on powerup attempting to use one or more as WAN is very bad idea. Until OpenWrt userspace scripts reconfigure switch they're bridged together causing security breach and hard to diagnose problems with for example DHCP.

Behaviour of CFE and problem it causes is documented in Wiki and has been for long time. There's only two good solutions: Either use device as it's intended (4 LAN AP) or hack CFE to not tamper with switch config and make it router+AP (3 LAN + 1 WAN).

Also using product_name nvram variable to detect WLA2-G54L is not good idea. This variable is only set by Buffalo firmware, not by CFE. Resetting nvram with mtd erase or holding reset button on bootup erases this variable. Below is nvram dump after holding reset and booting whiterussian b4128. I'm not sure if buffalo_id is uniq for this model. Perhaps you devs have more nvram dumps to compare.

root@OpenWrt:/# nvram show
os_ram_addr=80001000
wan_device=vlan1
boardrev=0x10
il0macaddr=00:0D:0B:B2:3F:FB
et0macaddr=00:0D:0B:B2:3F:FA
boot_wait=on
watchdog=1000
wl0_infra=1
et0mdcport=0
pmon_ver=CFE 1.0.37-1.00.0.02
wl0_ifname=eth1
gpio2=adm_eecs
gpio3=adm_eesk
gpio4=adm_eedi
gpio5=adm_rc
vlan0ports=1 2 3 4 5*
wl0_mode=ap
os_flash_addr=bfc40000
sromrev=2
boardtype=0x0101
lan_netmask=255.255.255.0
wl0_ssid=OpenWrt
wl0id=0x4320
pmon_date=Nov 16 2004 19:01:35
ag0=255
buffalo_id=29129
wl0gpio1=0
wl0gpio2=0
wl0gpio3=0
wl0gpio4=0
wl0gpio5=0
boardflags2=0
wan_proto=dhcp
memc_config=0x0004854a
pa0itssit=62
cctl=0
lan_ifnames=vlan0 eth1 eth2
pa0maxpwr=60
lan_proto=static
clkfreq=200
lan_ipaddr=192.168.11.1
vlan1hwname=et0
aa0=3
sdram_config=0x0032
vlan1ports=0 5
scratch=a0180000
ccode=0
lan_ifname=br0
boardflags=0x0188
sdram_refresh=0x0000
sdram_ncdl=0x22
et0phyaddr=30
wan_ifname=vlan1
wl0_radio=1
pa0b0=0x1136
pa0b1=0xfb93
pa0b2=0xfea5
sdram_init=0x000a
vlan0hwname=et0
dl_ram_addr=a0001000
boardnum=00
size: 1004 bytes (31764 left)
root@OpenWrt:/#

comment:6 Changed 10 years ago by florian

  • Resolution set to fixed
  • Status changed from assigned to closed

Re-fixed in [4193], thanks !

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.