I have a Tenda W311R and today I decided to update it`s firmware. I did an update and bricked my router (It seems that I used a different firmware for my version).
I decided to repair this router so I did some google search but no info available so I decided to figure out myself what to do (I have some experience with a wrt54gl, wrt54gs and a nslu2 units).
My unit is a W311R Version 2 or H2: 4MB Flash and 32MB RAM.
I opened the unit and I found this:
The 4MB KH29LV320CBTC-70G flash chip:
Two of 16MB HY57V281620FTP-H ram chips:
I had to find the serial output pins (RX and TX) and solder some wires to a connector like this:
I used a Z510 / Z710 modified usb cable ... it is a level converter because TENDA W311R RXD and TXD are (LV)TTL signals (0V/3.3V), not RS-232 signals (+/-12V).
You can build your own level converter or buy one from ebay.
Regarding the tftp server:
Create a folder called "tftp" to your c:\ partition and extract into the "tftp" folder the content of the archive "TENDA 20TFTP.zip" (TENDA TFTP.exe file), than move into the "tftp" folder the firmware that you want to upload (let`s call it "new_firmware.bin") and run "TENDA TFTP.exe", click the "browse" button and select "c:\tftp" and hit "ok". The tftp server it runs on port 69.
Now download "putty" from here -> http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
Run "putty.exe", setup -> on "Connection type" select "Serial", on "Host name" enter "COM3" (note I have COM3 but it might be any number you can check it in Device Manager) and click OPEN.
Now, using a UTP Cable connect your computer to the switch port 1-4 of the router, next connect the serial cable (level converter...etc) to the router and the power cable to the router (power led of the router will turn green).
Back to putty window:
As soon as you see in your putty window this output press 2 (key 2) you have 1 second to do that:
Quote:
Code:
U-Boot 1.1.3 (Feb 13 2009 - 09:48:32)
Board: Ralink APSoC DRAM: 32 MB
relocate_code Pointer at: 81fac000
flash_protect ON: from 0xBF000000 to 0xBF01FFAF
protect on 0
protect on 1
protect on 2
protect on 3
protect on 4
protect on 5
protect on 6
protect on 7
protect on 8
flash_protect ON: from 0xBF030000 to 0xBF03FFFF
protect on 10
*** Warning - bad CRC, using default environment
Please choose the operation:
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
9: Load Boot Loader code then write to Flash via TFTP.
Press 2 fast (max 1 second to do that...you need to be fast)
ETH_STATE_ACTIVE!!
Using Eth0 (10/100-M) device
TFTP from server 192.168.0.2; our IP address is 192.168.0.1
Filename 'new_firmware.bin'.
TIMEOUT_COUNT=10,Load address: 0x80100000
Loading: Got ARP REPLY, set server/gtwy eth addr (xx:xx:xx:xx:xx:xx)
Got it
T #
first block received
################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#####################################################
done
Bytes transferred = 2263332 (228924 hex)
NetBootFileXferSize= 00228924
Erase linux kernel block !!
From 0xBF050000 To 0xBF27FFFF
b_end =BF3FFFFF
Erase Flash from 0xbf050000 to 0xbf27ffff in Bank # 1
System Control Status = 0x20440000
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 2263268 Bytes = 2.2 MB
Load Address: 80000000
Entry Point: 803cd000
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 803cd000) ...
## Giving linux memsize in MB, 32
Starting kernel ...
LINUX started...
THIS IS ASIC
Linux version 2.6.21 (root@linux-6091) (gcc version 3.4.2) #452 Mon Feb 9 21:25:31 CST 2009
The CPU feqenuce set to 384 MHz
CPU revision is: 0001964c
Determined physical RAM map:
memory: 02000000 @ 00000000 (usable)
Initrd not found or empty - disabling initrd
Built 1 zonelists. Total pages: 8128
Kernel command line: console=ttyS1,57600n8 root=/dev/ram0
Primary instruction cache 32kB, physically tagged, 4-way, linesize 32 bytes.
Primary data cache 16kB, 4-way, linesize 32 bytes.
Synthesized TLB refill handler (20 instructions).
Synthesized TLB load handler fastpath (32 instructions).
Synthesized TLB store handler fastpath (32 instructions).
Synthesized TLB modify handler fastpath (31 instructions).
Cache parity protection disabled
cause = 800068, status = 1100ff00
PID hash table entries: 128 (order: 7, 512 bytes)
calculating r4koff... 00177000(1536000)
CPU frequency 384.00 MHz
Using 192.000 MHz high precision timer.
Console: colour dummy device 80x25
Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
Memory: 27328k/32768k available (3378k kernel code, 5440k reserved, 510k data, 1116k init, 0k highmem)
Mount-cache hash table entries: 512
NET: Registered protocol family 16
NET: Registered protocol family 2
Time: MIPS clocksource has been installed.
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 1024 (order: 1, 8192 bytes)
TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
TCP: Hash tables configured (established 1024 bind 1024)
TCP reno registered
detected lzma initramfs
detected lzma initramfs
initramfs: LZMA lc=3,lp=0,pb=2,dictSize=1048576,origSize=3976704
LZMA initramfs by Ming-Ching Tiew <mctiew@yahoo.com>.............................................................Load RT2880 Timer Module(Wdg/Soft)
squashfs: version 3.2-r2 (2007/01/15) Phillip Lougher
squashfs: LZMA suppport for slax.org by jro
io scheduler noop registered (default)
FLASH_API: MAN_ID=C2 DEV_ID=22A8 SIZE=4MB
Ralink gpio driver initialized
HDLC line discipline: version $Revision: 1.1.1.1 $, maxframe=4096
N_HDLC line discipline registered.
Serial: 8250/16550 driver $Revision: 1.3 $ 2 ports, IRQ sharing disabled
serial8250: ttyS0 at I/O 0xb0000500 (irq = 37) is a 16550A
serial8250: ttyS1 at I/O 0xb0000c00 (irq = 12) is a 16550A
RAMDISK driver initialized: 16 RAM disks of 8192K size 1024 blocksize
loop: loaded (max 8 devices)
rdm_major = 254
GDMA1_MAC_ADRH -- : 0x00000000
GDMA1_MAC_ADRL -- : 0x00000000
Ralink APSoC Ethernet Driver Initilization. v1.60 256 rx/tx descriptors allocated, mtu = 1500!
NAPI enable, weight = 0, Tx Ring = 256, Rx Ring = 256
GDMA1_MAC_ADRH -- : 0x00000100
GDMA1_MAC_ADRL -- : 0x000c4330
PROC INIT OK!
PPP generic driver version 2.4.2
PPP BSD Compression module registered
NET: Registered protocol family 24
2860 version : 2.0.0.0 (Feb 9 2009)
=== pAd = c0000000, size = 485320 ===
<-- RTMPAllocAdapterBlock, Status=0
ralink flash device: 0x1000000 at 0xbf000000
Ralink SoC physically mapped flash: Found 1 x16 devices at 0x0 in 16-bit bank
Amd/Fujitsu Extended Query Table at 0x0040
number of CFI chips: 1
cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
Creating 4 MTD partitions on "Ralink SoC physically mapped flash":
0x00000000-0x00030000 : "Bootloader"
0x00030000-0x00040000 : "Config"
0x00040000-0x00050000 : "Factory"
0x00050000-0x00400000 : "Kernel"
block2mtd: version $Revision: 1.1.1.1 $
nf_conntrack version 0.5.0 (256 buckets, 2048 max)
arp_tables: (C) 2002 David S. Miller
IPv4 over IPv4 tunneling driver
GRE over IPv4 tunneling driver
ip_tables: (C) 2000-2006 Netfilter Core Team, Type=Fully Cone
TCP cubic registered
NET: Registered protocol family 1
NET: Registered protocol family 10
NET: Registered protocol family 17
802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
All bugs added by David S. Miller <davem@redhat.com>
Freeing unused kernel memory: 1116k freed
init started: BusyBox v1.12.1 (2009-02-09 21:19Algorithmics/MIPS FPU Emulator v1.5
:29 CST)
starting pid 14, tty '': '/etc_ro/rcS'
devpts: called with bogus options
mount: mounting none on /proc/bus/usb failed: No such file or directory
Welcome to
_______ _______ ___ __ ____ _kernel reg pid 21 success .
_ ___
| ___ \| __ || | |__|| \ | || | / /
| |___| || |__| || |__ __ | \| || |/ /
| _ /| _ || || || |\ || \
|__| \__\|__| |__||______||__||_| \____||_|\___\
phy_rx_ring = 0x01d82000, rx_ring = 0xa1d82000, size: 16 bytes
GDMA1_FWD_CFG = 10000
eth2.1: Setting MAC address to xx xx xx xx xx xx.
VLAN (eth2.1): Underlying device (eth2) has same MAC, not checking promiscious mode.
eth2.2: Setting MAC address to xx xx xx xx xx xx.
device eth2 entered promiscuous mode
VLAN (eth2.2): Setting underlying device (eth2) to promiscious mode.
getIfLive: device br0 not found.
eth2.1: dev_set_promiscuity(master, 1)
device eth2.1 entered promiscuous mode
Router ip address config success.
br0: port 1(eth2.1) entering learning state
device ra0 entered promiscuous mode
br0: port 2(ra0) entering learning state
libupnp: using UDP SSDP_PORT = 1900
br0: topology change detected, propagating
br0: port 1(eth2.1) entering forwarding state
br0: topology change detected, propagating
br0: port 2(ra0) entering forwarding state
killall: udhcpd: no process killed
ND -> Bad_Sig_entry [18]...
httpd listen ip = 192.168.0.1 port = 80
MfgThread start loop.
TendaLog -> ok rtn.
macBcast uses obsolete (PF_INET,SOCK_PACKET)
IsSameNET [192.168.0.1/255.255.255.0][192.168.1.1/255.255.255.0]
sntp: host not found
killall: dnrd: no process killed
iptables: Bad rule (does a matching rule exist in that chain?)
iptables: Bad rule (does a matching rule exist in that chain?)
route: ioctl 0x890b failed: File exists
libupnp: using UDP SSDP_PORT = 1900
upnpd[289]: UPnP SDK Successfully Initialized.
Mar 29 09:36:22 upnpd[289]: UPnP SDK Successfully Initialized.
upnpd[289]: Succesfully set the Web Server Root Directory.
Mar 29 09:36:22 upnpd[289]: Succesfully set the Web Server Root Directory.
upnpd[289]: IGD root device successfully registered.
Mar 29 09:36:23 upnpd[289]: IGD root device successfully registered.
iptables: No chain/target/match by that name
iptables: No chain/target/match by that name
iptables: No chain/target/match by that name
Startnat end.
upnpd[289]: Advertisements Sent. Listening for requests ...
Mar 29 09:36:25 upnpd[289]: Advertisements Sent. Listening for requests ...
............ wan unlink ..4.
............ wan unlink ..5.
Now your router is back on track and it can be accessed from http://192.168.0.1 with user: admin and password: admin . Don`t forget to do a "reset to default" to be sure that all settings are set to default.
(On the putty window I am able to execute linux commands...like cat /proc/cpuinfo , cat /proc/meminfo , ls...)
I am able to do some tests and maybe we can install dd-wrt on it (I have no idea how so I need to be guided...).
Please excuse my english...
I hope that my tutorial will help a few people...if someone needs help please ask!
Last edited by kapastratos on Fri Jan 27, 2012 20:24; edited 3 times in total
Thank you for finding that out! Had the same problem with wrong firmware-update. I saw the two pads on the backside of the PCB but had no time to test on them. I think it should be possible to load the DD-WRT of DIR300 Rev.B on the unit. Have to solder a serial cable first to get my unit alive again.
Today I will try to flash the dd-wrt firmware for the DIR-300 B1 router to my Tenda W311R H2 router. Both units are using the RT3050 chipset so it might work. I will let you know in a few hours!
======LATER EDIT======
Ok, I did some tests and I was able to flash my Tenda W311R with dd-wrt firmware for DIR-300 B1 but it wasn`t booting because I got this error "Bad Magic Number":
Quote:
Code:
U-Boot 1.1.3 (Feb 13 2009 - 09:48:32)
Board: Ralink APSoC DRAM: 32 MB
relocate_code Pointer at: 81fac000
flash_protect ON: from 0xBF000000 to 0xBF01FFAF
protect on 0
protect on 1
protect on 2
protect on 3
protect on 4
protect on 5
protect on 6
protect on 7
protect on 8
flash_protect ON: from 0xBF030000 to 0xBF03FFFF
protect on 10
*** Warning - bad CRC, using default environment
Please choose the operation:
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
9: Load Boot Loader code then write to Flash via TFTP. 0
3: System Boot system code via Flash.
## Booting image at bf050000 ...
Bad Magic Number,48445230
I did a forum search and I found this: http://www.dd-wrt.com/phpBB2/viewtopic.php?t=55600. I hexedit the firmware using XVI32 and I flashed my router again and it seems to boot a few steps then it stops:
Quote:
Code:
U-Boot 1.1.3 (Feb 13 2009 - 09:48:32)
Board: Ralink APSoC DRAM: 32 MB
relocate_code Pointer at: 81fac000
flash_protect ON: from 0xBF000000 to 0xBF01FFAF
protect on 0
protect on 1
protect on 2
protect on 3
protect on 4
protect on 5
protect on 6
protect on 7
protect on 8
flash_protect ON: from 0xBF030000 to 0xBF03FFFF
protect on 10
*** Warning - bad CRC, using default environment
Please choose the operation:
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
9: Load Boot Loader code then write to Flash via TFTP. 0
3: System Boot system code via Flash.
## Booting image at bf050000 ...
Image Name: DD-WRT v24 Linux Kernel Image
Created: 2009-10-10 9:41:26 UTC
System Control Status = 0x20440000
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 864813 Bytes = 844.5 kB
Load Address: 80000000
Entry Point: 8026d000
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 8026d000) ...
## Giving linux memsize in MB, 32
Starting kernel ...
LINUX started...
THIS IS ASIC
Linux version 2.6.23.17 (root@dd-wrt) (gcc version 4.1.2) #969 Sat Oct 10 11:37:40 CEST 2009
The CPU frequency set to 384 MHz
32M RAM Detected!
CPU revision is: 0001964c
Determined physical RAM map:
memory: 02000000 @ 00000000 (usable)
Built 1 zonelists in Zone order. Total pages: 8128
Kernel command line: console=ttyS1,57600n8 root=/dev/mtdblock4 rootfstype=squashfs noinitrd
Primary instruction cache 32kB, physically tagged, 4-way, linesize 32 bytes.
Primary data cache 16kB, 4-way, linesize 32 bytes.
Synthesized TLB refill handler (20 instructions).
Synthesized TLB load handler fastpath (32 instructions).
Synthesized TLB store handler fastpath (32 instructions).
Synthesized TLB modify handler fastpath (31 instructions).
Cache parity protection disabled
cause = 800078, status = 1100ff00
PID hash table entries: 128 (order: 7, 512 bytes)
calculating r4koff... 003a9800(3840000)
CPU frequency 384.00 MHz
Using 192.000 MHz high precision timer.
console [ttyS1] enabled
Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
Memory: 29480k/32768k available (2159k kernel code, 3288k reserved, 320k data, 120k init, 0k highmem)
Mount-cache hash table entries: 512
NET: Registered protocol family 16
Generic PHY: Registered new driver
NET: Registered protocol family 2
Time: MIPS clocksource has been installed.
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 1024 (order: 1, 8192 bytes)
TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
TCP: Hash tables configured (established 1024 bind 1024)
TCP reno registered
Load RT2880 Timer Module(Wdg/Soft)
devfs: 2004-01-31 Richard Gooch (rgooch@atnf.csiro.au)
devfs: boot_options: 0x1
squashfs: version 3.0 (2006/03/15) Phillip Lougher
io scheduler noop registered
io scheduler deadline registered (default)
Ralink gpio driver initialized
Serial: 8250/16550 driver $Revision: 1.3 $ 2 ports, IRQ sharing disabled
serial8250: ttyS0 at I/O 0xb0000500 (irq = 37) is a 16550A
serial8250: ttyS1 at I/O 0xb0000c00 (irq = 12) is a 16550A
rt3052 access driver initialization.
PPP generic driver version 2.4.2
PPP Deflate Compression module registered
PPP BSD Compression module registered
MPPE/MPPC encryption/compression module registered
NET: Registered protocol family 24
PPPoL2TP kernel driver, V1.0
tun: Universal TUN/TAP device driver, 1.6
tun: (C) 1999-2004 Max Krasnyansky <maxk@qualcomm.com>
ralink flash device: 0x1000000 at 0xbf000000
Ralink SoC physically mapped flash: Found 1 x16 devices at 0x0 in 16-bit bank
Amd/Fujitsu Extended Query Table at 0x0040
number of CFI chips: 1
cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
found squashfs at 124000
Creating 6 MTD partitions on "Ralink SoC physically mapped flash":
0x00000000-0x00030000 : "uboot"
0x00030000-0x00040000 : "uboot-config"
0x00040000-0x00050000 : "factory-defaults"
0x00050000-0x003f0000 : "linux"
0x00124000-0x003f0000 : "rootfs"
mtd: partition "rootfs" doesn't start on an erase block boundary -- force read-only
0x003f0000-0x00400000 : "nvram"
u32 classifier
Actions configured
Netfilter messages via NETLINK v0.30.
nf_conntrack version 0.5.0 (1024 buckets, 4096 max)
ctnetlink v0.93: registering with nfnetlink.
IPv4 over IPv4 tunneling driver
GRE over IPv4 tunneling driver
ip_tables: (C) 2000-2006 Netfilter Core Team
IPP2P v0.8.2 loading
ClusterIP Version 0.8 loaded successfully
TCP bic registered
TCP cubic registered
TCP westwood registered
TCP highspeed registered
TCP hybla registered
TCP htcp registered
TCP vegas registered
TCP scalable registered
NET: Registered protocol family 1
NET: Registered protocol family 17
Welcome to PF_RING 3.2.1
(C) 2004-06 L.Deri <deri@ntop.org>
NET: Registered protocol family 27
PF_RING: bucket length 128 bytes
PF_RING: ring slots 4096
PF_RING: sample rate 1 [1=no sampling]
PF_RING: capture TX No [RX only]
PF_RING: transparent mode Yes
PF_RING initialized correctly.
PF_RING: registered /proc/net/pf_ring/
802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
All bugs added by David S. Miller <davem@redhat.com>
GDMA1_MAC_ADRH -- : 0x00000000
GDMA1_MAC_ADRL -- : 0x00000000
Ralink APSoC Ethernet Driver Initilization. v2.00 256 rx/tx descriptors allocated, mtu = 1500!
NAPI enable, weight = 0, Tx Ring = 256, Rx Ring = 256
GDMA1_MAC_ADRH -- : 0x0000000c
GDMA1_MAC_ADRL -- : 0x43305277
PROC INIT OK!
decode /dev/mtdblock4
VFS: Mounted root (squashfs filesystem) readonly.
Mounted devfs on /dev
Freeing unused kernel memory: 120k freed
starting Architecture code for rt2880
switch reg write offset=14, value=405555
switch reg write offset=50, value=2001
switch reg write offset=98, value=7f3f
switch reg write offset=e4, value=3f
switch reg write offset=40, value=1001
switch reg write offset=44, value=1001
switch reg write offset=48, value=1002
switch reg write offset=70, value=ffff506f
sh: ead: not found
wland: No such file or directory
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
vlan2: No such process
iptables-restore: line 69 failed
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
wland: No such file or directory
So my dd-wrt tests has stopped because I have no idea what to do next.
I had to test a dir-300 b1 original firmware to this router and the router is working with this firmware (DIR300B1_FW201WWB01.bin) but it seems that the wan port it is recognized as a switch port...anything it`s working (wireless is working) so it can be used as an access point with 5 switch ports...I don`t know if it is stable. I had to hexedit the firmware as described above.
If I do more tests I will let people know!
======LATER EDIT======
Back with some news, I flashed again to DIR-300 B1 V.2.01 firmware to run more tests and I found out that the ports are in a different order and that the wan port it is working...the order is like this:
Switch port 4 changed to WAN Port
Switch port 3 changed to Switch port 1
Switch port 2 changed to Switch port 2
Switch port 1 changed to Switch port 3
WAN Port changed to Switch port 4
I tested both...wireless and cable connection and it is working 100% and it is stable.
So now my TENDA W311R H2 router is a DIR-300 B1 router.
I am unable to find why the dd-wrt firmware designed for DIR-300 B1 it is not working on W311R H2 and why the d-link firmware designed for DIR-300 B1 it is working on W311R H2.
I will continue testing this "brain washed" router.
======LATER EDIT======
I successfully installed DD-WRT FIRMWARE to my Tenda W311R Router. It was working from the first time but I was checking for the router on 192.168.0.1 and the router flashed with dd-wrt was on 192.168.1.1 ... I had to sleep for a few hours and when I woke up it camed "check for the router on 192.168.1.1 or check if any wireless network called "dd-wrt" it`s there" , I checked and it was there, waiting for my ping .
Now I have to do some tests to see if it is stable and if everything it is working. The firmware that I used is DD-WRT for dir-300 B1 version but I had to hexedit it te get rid of that "bad magic number" (check above) how can be done!
Again good news! I think the Developers can fix the problem with the "bad magic number" permanently but don´t know if they put the W311R to the supported device list if they don´t have any device for themselves. Let´s see...
Ok, i did it, build a serial adapter with a MAX232 and two resistors on the tx-output for the W311R (to get 3,3V) It´s working again! Flashed it with DD-WRT, yeah ...
@kapastratos
You can only get serial connection at 57600 Baud, you forget to mention in your discription...
Ok, i flashed my second Tenda with the same procedure but now got a problem. The NVRAM settings seems to be corrupt, but i don´t know how to reset them. Hardware-Reset doesn´t help. I tried to run "erase 0x003f0000 0x00400000" on U-Boot but does not work. Any advice on this?
Ok, i flashed my second Tenda with the same procedure but now got a problem. The NVRAM settings seems to be corrupt, but i don´t know how to reset them. Hardware-Reset doesn´t help. I tried to run "erase 0x003f0000 0x00400000" on U-Boot but does not work. Any advice on this?
Please choose the operation:
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
9: Load Boot Loader code then write to Flash via TFTP. 0
3: System Boot system code via Flash.
## Booting image at bf050000 ...
Image Name: DD-WRT v24 Linux Kernel Image
Created: 2009-12-28 12:13:02 UTC
System Control Status = 0x20440000
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 864847 Bytes = 844.6 kB
Load Address: 80000000
Entry Point: 8026d000
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 8026d000) ...
## Giving linux memsize in MB, 32
Starting kernel ...
LINUX started...
THIS IS ASIC
Linux version 2.6.23.17 (root@dd-wrt) (gcc version 4.1.2) #1474 Mon Dec 28 13:09:23 CET 2009
The CPU frequency set to 384 MHz
32M RAM Detected!
CPU revision is: 0001964c
Determined physical RAM map:
memory: 02000000 @ 00000000 (usable)
Built 1 zonelists in Zone order. Total pages: 8128
Kernel command line: console=ttyS1,57600n8 root=/dev/mtdblock4 rootfstype=squashfs noinitrd
Primary instruction cache 32kB, physically tagged, 4-way, linesize 32 bytes.
Primary data cache 16kB, 4-way, linesize 32 bytes.
Synthesized TLB refill handler (20 instructions).
Synthesized TLB load handler fastpath (32 instructions).
Synthesized TLB store handler fastpath (32 instructions).
Synthesized TLB modify handler fastpath (31 instructions).
Cache parity protection disabled
cause = 90800060, status = 1100ff00
PID hash table entries: 128 (order: 7, 512 bytes)
calculating r4koff... 003a9800(3840000)
CPU frequency 384.00 MHz
Using 192.000 MHz high precision timer.
console [ttyS1] enabled
Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
Memory: 29480k/32768k available (2159k kernel code, 3288k reserved, 320k data, 120k init, 0k highmem)
Mount-cache hash table entries: 512
NET: Registered protocol family 16
Generic PHY: Registered new driver
NET: Registered protocol family 2
Time: MIPS clocksource has been installed.
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 1024 (order: 1, 8192 bytes)
TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
TCP: Hash tables configured (established 1024 bind 1024)
TCP reno registered
Load RT2880 Timer Module(Wdg/Soft)
devfs: 2004-01-31 Richard Gooch (rgooch@atnf.csiro.au)
devfs: boot_options: 0x1
squashfs: version 3.0 (2006/03/15) Phillip Lougher
io scheduler noop registered
io scheduler deadline registered (default)
Ralink gpio driver initialized
Serial: 8250/16550 driver $Revision: 1.3 $ 2 ports, IRQ sharing disabled
serial8250: ttyS0 at I/O 0xb0000500 (irq = 37) is a 16550A
serial8250: ttyS1 at I/O 0xb0000c00 (irq = 12) is a 16550A
rt3052 access driver initialization.
PPP generic driver version 2.4.2
PPP Deflate Compression module registered
PPP BSD Compression module registered
MPPE/MPPC encryption/compression module registered
NET: Registered protocol family 24
PPPoL2TP kernel driver, V1.0
tun: Universal TUN/TAP device driver, 1.6
tun: (C) 1999-2004 Max Krasnyansky <maxk@qualcomm.com>
ralink flash device: 0x1000000 at 0xbf000000
Ralink SoC physically mapped flash: Found 1 x16 devices at 0x0 in 16-bit bank
Amd/Fujitsu Extended Query Table at 0x0040
number of CFI chips: 1
cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
found squashfs at 124000
Creating 6 MTD partitions on "Ralink SoC physically mapped flash":
0x00000000-0x00030000 : "uboot"
0x00030000-0x00040000 : "uboot-config"
0x00040000-0x00050000 : "factory-defaults"
0x00050000-0x003f0000 : "linux"
0x00124000-0x003f0000 : "rootfs"
mtd: partition "rootfs" doesn't start on an erase block boundary -- force read-only
0x003f0000-0x00400000 : "nvram"
u32 classifier
Actions configured
Netfilter messages via NETLINK v0.30.
nf_conntrack version 0.5.0 (1024 buckets, 4096 max)
ctnetlink v0.93: registering with nfnetlink.
IPv4 over IPv4 tunneling driver
GRE over IPv4 tunneling driver
ip_tables: (C) 2000-2006 Netfilter Core Team
IPP2P v0.8.2 loading
ClusterIP Version 0.8 loaded successfully
TCP bic registered
TCP cubic registered
TCP westwood registered
TCP highspeed registered
TCP hybla registered
TCP htcp registered
TCP vegas registered
TCP scalable registered
NET: Registered protocol family 1
NET: Registered protocol family 17
Welcome to PF_RING 3.2.1
(C) 2004-06 L.Deri <deri@ntop.org>
NET: Registered protocol family 27
PF_RING: bucket length 128 bytes
PF_RING: ring slots 4096
PF_RING: sample rate 1 [1=no sampling]
PF_RING: capture TX No [RX only]
PF_RING: transparent mode Yes
PF_RING initialized correctly.
PF_RING: registered /proc/net/pf_ring/
802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
All bugs added by David S. Miller <davem@redhat.com>
GDMA1_MAC_ADRH -- : 0x00000000
GDMA1_MAC_ADRL -- : 0x00000000
Ralink APSoC Ethernet Driver Initilization. v2.00 256 rx/tx descriptors allocated, mtu = 1500!
NAPI enable, weight = 0, Tx Ring = 256, Rx Ring = 256
GDMA1_MAC_ADRH -- : 0x0000000c
GDMA1_MAC_ADRL -- : 0x43305277
PROC INIT OK!
decode /dev/mtdblock4
VFS: Mounted root (squashfs filesystem) readonly.
Mounted devfs on /dev
Freeing unused kernel memory: 120k freed
start service
starting Architecture code for rt2880
rt2860v2_ap: module license 'unspecified' taints kernel.
Invalid nvram magic 5471 48534C46
phy_rx_ring = 0x01d77000, rx_ring = 0xa1d77000, size: 16 bytes
RT305x_ESW: Link Status Changed
GDMA1_FWD_CFG = 10000
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
switch reg write offset=14, value=405555
switch reg write offset=50, value=2001
switch reg write offset=98, value=7f3f
switch reg write offset=e4, value=3f
switch reg write offset=40, value=1001
switch reg write offset=44, value=1001
switch reg write offset=48, value=1002
switch reg write offset=70, value=ffff506f
br0: Dropping NETIF_F_UFO since no NETIF_F_HW_CSUM feature.
Invalid nvram magic 5471 48534C46
Algorithmics/MIPS FPU Emulator v1.5
device vlan1 entered promiscuous mode
device eth2 entered promiscuous mode
sh: ead: not found
RtmpOSNetDevDetach(): RtmpOSNetDeviceDetach(), dev->name=ra0!
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
0x1300 = 00064380
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
Invalid nvram magic 5471 48534C46
0x1300 = 00064380
device ra0 entered promiscuous mode
br0: port 2(ra0) entering learning state
br0: port 1(vlan1) entering learning state
wland: No such file or directory
device vlan2 entered promiscuous mode
device vlan2 left promiscuous mode
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGS: No such device
SIOCGIFFLAGSbr0: topology change detected, propagating
: No such devicebr0: port 2(ra0) entering forwarding state
br0: topology change detected, propagating
br0: port 1(vlan1) entering forwarding state
SIOCGIFFLAGS: No such device
etherip: Ethernet over IPv4 tunneling driver
Invalid nvram magic 5471 48534C46
There´s no wireless working, but access to Webinterface is normal. This W311R has an abnormal behavior even with the original firmware, i think the device was not really new as i received it
Joined: 06 Jun 2006 Posts: 7463 Location: Dresden, Germany
Posted: Sun Jan 17, 2010 18:03 Post subject:
shivasdream wrote:
Ok, i flashed my second Tenda with the same procedure but now got a problem. The NVRAM settings seems to be corrupt, but i don´t know how to reset them. Hardware-Reset doesn´t help. I tried to run "erase 0x003f0000 0x00400000" on U-Boot but does not work. Any advice on this?
thats the right way to erase the nvram sector. dd-wrt will the recover any bad setting. _________________ "So you tried to use the computer and it started smoking? Sounds like a Mac to me.." - Louis Rossmann https://www.youtube.com/watch?v=eL_5YDRWqGE&t=60s