OpenWrt Forum Archive

Topic: Is this router based on the infineon danube?

The content of this topic has been archived between 1 Oct 2014 and 1 May 2018. Unfortunately there are posts – most likely complete pages – missing.

Ok, I have uboot running:

[DANUBE Boot]:y

Go to Memory Address: (default:0x80002000) : 0x
Jump to address 0x80002000 ...                 


U-Boot 2010.03 (Oct 28 2010 - 21:50:55)

Board: Danube/Twinpass/Vinax-VE V1.5, DDR Speed 166 MHz, CPU Speed 333 MHz
DRAM:  64 MB                                                              
Flash:  8 MB                                                              
*** Warning - bad CRC, using default environment                          

Net:   
searching for rtl8306 switch ... lq_cpe_eth

Type "run flash_nfs" to mount root filesystem over NFS

Hit any key to stop autoboot:  0 
ARV4518 => ?                     
?       - alias for 'help'       
base    - print or set address offset
bdinfo  - print Board Info structure 
boot    - boot default, i.e., run 'bootcmd'
bootd   - boot default, i.e., run 'bootcmd'
bootm   - boot application image from memory
bootp   - boot image via network using BOOTP/TFTP protocol
cmp     - memory compare                                  
cp      - memory copy                                     
crc32   - checksum calculation                            
echo    - echo args to console                            
editenv - edit environment variable                       
erase   - erase FLASH memory                              
flinfo  - print FLASH memory information                  
go      - start application at address 'addr'             
help    - print command description/usage                 
httpd   - httpd - start webserver                         
iminfo  - print header information for application image  
itest   - return true/false on integer compare            
loop    - infinite loop on address range                  
md      - memory display                                  
mii     - MII utility commands                            
mm      - memory modify (auto-incrementing address)       
mtest   - simple RAM read/write test                      
mw      - memory write (fill)                             
nm      - memory modify (constant address)                
ping    - send ICMP ECHO_REQUEST to network host          
printenv- print environment variables                     
protect - enable or disable FLASH write protection        
rarpboot- boot image via network using RARP/TFTP protocol 
reset   - Perform RESET of the CPU                        
run     - run commands in an environment variable         
saveenv - save environment variables to persistent storage
setenv  - set environment variables                       
sleep   - delay execution for some time                   
source  - run script from memory                          
tftpboot- boot image via network using TFTP protocol      
version - print monitor version                           
ARV4518 => version                                        

U-Boot 2010.03 (Oct 28 2010 - 21:50:55)
ARV4518 => printenv                    
bootcmd=run flash_flash                
bootdelay=5                            
baudrate=115200                        
loads_echo=                            
ipaddr=192.168.2.1                     
serverip=192.168.2.101                 
preboot=echo;echo Type \"run flash_nfs\" to mount root filesystem over NFS;echo
rootpath="/export"                                                             
gatewayip=192.168.2.254                                                        
netmask=255.255.255.0                                                          
ram_addr=0x80500000                                                            
kernel_addr=0xb007d000                                                         
mtdparts=mtdparts=ifx-nor:128k(brnboot)ro,256k(brn_env)ro,58k(uboot)ro,58k(uboot_env)ro,64k(kernel),-(rootfs)
flashargs=setenv bootargs rootfstype=squashfs,jffs2                                                          
nfsargs=setenv bootargs root=/dev/nfs rw nfsroot=${serverip}:${rootpath}                                     
addip=setenv bootargs ${bootargs} ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}:${netdev}:off 
addmisc=setenv bootargs ${bootargs} init=/etc/preinit console=ttyS1,115200 ethaddr=${ethaddr} ${mtdparts}    
flash_flash=run flashargs addip addmisc;bootm ${kernel_addr}                                                 
flash_nfs=run nfsargs addip addmisc;bootm ${kernel_addr}                                                     
net_flash=run load_kernel flashargs addip addmisc;bootm ${ram_addr}                                          
net_nfs=run load_kernel nfsargs addip addmisc;bootm ${ram_addr}                                              
load_kernel=tftp ${ram_addr} ${tftppath}openwrt-ifxmips-uImage                                               
update_uboot=tftp 0x80500000 ${tftppath}u-boot.bin;era 0xb0060000 +${filesize};cp.b 0x80500000 0xb0060000 ${filesize}
update_openwrt=tftp ${ram_addr} ${tftppath}openwrt-ifxmips-squashfs.image;era ${kernel_addr} +${filesize};cp.b ${ram_addr} ${kernel_addr} ${filesize}
bootcmd=bootm 0xb007d000                                                                                                                             
stdin=serial                                                                                                                                         
stdout=serial                                                                                                                                        
stderr=serial                                                                                                                                        
ethaddr=73:8f:e6:46:7a:b0                                                                                                                            
ethact=lq_cpe_eth                                                                                                                                    
ver=U-Boot 2010.03 (Oct 28 2010 - 21:50:55)                                                                                                          

Environment size: 1480/65532 bytes
ARV4518 => bdinfo                 
boot_params = 0x83E9FFB8          
memstart    = 0x80000000          
memsize     = 0x04000000          
flashstart  = 0xB0000000          
flashsize   = 0x00800000          
flashoffset = 0x00000000          
ethaddr     = 73:8f:e6:46:7a:b0   
ip_addr     = 192.168.2.1         
baudrate    = 115200 bps

However the network doesn't work. I didn't look at it before, but this board uses a different switch, an atheros ar8216 sad

Edit: btw, the wifi chip is an ar9223 (though I'm not really interested in wifi, wife banned it at home wink)

(Last edited by pippolippi on 31 Oct 2010, 15:12)

Hi:

Use a higher address, because kernel then decompress to 0x80010000. For example 80400000 is  what I have used.
But the problem is that no switch, no network. :-(
Sometimes, the brn bootloader initializes the switch. Do lan leds work? Can you do a ping?

Hi:

By the way, you would heve two potential problems with the swith: First one: Connection between CPU and switch (MII, Rev. MII, serial io, clocks) and  and the second the switchs initialization. Try the mii commands.

ngp wrote:

Hi:

Use a higher address, because kernel then decompress to 0x80010000. For example 80400000 is  what I have used.

Ok (even though I edited out that part of the question when I noticed that the network doesn't work).

ngp wrote:

But the problem is that no switch, no network. :-(
Sometimes, the brn bootloader initializes the switch. Do lan leds work? Can you do a ping?

Well, that's how I noticed it has a different switch: no ping sad
The led lights up when I plug in the cable, but it shows no activity when I try to ping.

ngp wrote:

Try the mii commands.

For example?

mii info, mii dump... Sorry, i wont have access to my router till tuesday.

I uploaded both uboot and the kernel with xmodem (it takes forever sad) and this is the result:

ARV4518 => bootm 0x80400000         
## Booting kernel from Legacy Image at 80400000 ...
   Image Name:   MIPS OpenWrt Linux-2.6.33.7       
   Created:      2010-10-28  18:34:29 UTC          
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    2208638 Bytes =  2.1 MB                  
   Load Address: 80002000                                 
   Entry Point:  80002000                                 
   Verifying Checksum ... OK                              
   Uncompressing Kernel Image ... LZMA: uncompress or overwrite error 1 - must RESET b

and then the router reboots.

Could it be because it's at the same address than uboot?
Edit: or because the uncompressed kernel overwrites the compressed image (the kernel is 7MB, it goes to 806e24ac)?

(Last edited by pippolippi on 31 Oct 2010, 17:58)

argh. my fault. 80400000 only leaves 4 mb for kernel.  80800000 or higher, sorry. Uboot isnt the problem, it copies itself to the top of memory and runs from there

The kernel boots ok, but the network doesn't work. I suppose your kernel hasn't support for the switch (it should be in the kernel sources though).

ARV4518 => bootm 0x80700000      
## Booting kernel from Legacy Image at 80700000 ...
   Image Name:   MIPS OpenWrt Linux-2.6.33.7       
   Created:      2010-10-28  18:34:29 UTC          
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    2208638 Bytes =  2.1 MB                  
   Load Address: 80002000                                 
   Entry Point:  80002000                                 
   Verifying Checksum ... OK                              
   Uncompressing Kernel Image ... OK                      

Starting kernel ...

Linux version 2.6.33.7 (norberto@orion) (gcc version 4.3.3 (GCC) ) #22 Thu Oct 28 20:34:09 CEST 2010
bootconsole [early0] enabled                                                                        
CPU revision is: 00019641 (MIPS 24Kc)                                                               
Determined physical RAM map:                                                                        
 memory: 04000000 @ 00000000 (usable)                                                               
Initrd not found or empty - disabling initrd                                                        
Zone PFN ranges:                                                                                    
  Normal   0x00000000 -> 0x00004000                                                                 
Movable zone start PFN for each node                                                                
early_node_map[1] active PFN ranges                                                                 
    0: 0x00000000 -> 0x00004000                                                                     
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256                          
Kernel command line: console=ttyS0,115200 rootfstype=squashfs,jffs2 console=ttyS0,9600 console=ttyS1,115200n8 rootfstype=squashfs,jffs2
PID hash table entries: 256 (order: -2, 1024 bytes)                                                                                    
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)                                                                          
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)                                                                           
Primary instruction cache 16kB, VIPT, 4-way, linesize 32 bytes.                                                                        
Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 32 bytes                                                                    
Writing ErrCtl register=0007fad8                                                                                                       
Readback ErrCtl register=0007fad8                                                                                                      
Memory: 57724k/65536k available (2181k kernel code, 7736k reserved, 374k data, 4484k init, 0k highmem)                                 
Hierarchical RCU implementation.                                                                                                       
NR_IRQS:256                                                                                                                            
Linux version 2.6.33.7 (norberto@orion) (gcc version 4.3.3 (GCC) ) #22 Thu Oct 28 20:34:09 CEST 2010                                   
bootconsole [early0] enabled                                                                                                           
CPU revision is: 00019641 (MIPS 24Kc)                                                                                                  
Determined physical RAM map:                                                                                                           
 memory: 04000000 @ 00000000 (usable)                                                                                                  
Initrd not found or empty - disabling initrd                                                                                           
Zone PFN ranges:                                                                                                                       
  Normal   0x00000000 -> 0x00004000                                                                                                    
Movable zone start PFN for each node                                                                                                   
early_node_map[1] active PFN ranges                                                                                                    
    0: 0x00000000 -> 0x00004000                                                                                                        
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256                                                             
Kernel command line: console=ttyS0,115200 rootfstype=squashfs,jffs2 console=ttyS0,9600 console=ttyS1,115200n8 rootfstype=squashfs,jffs2
PID hash table entries: 256 (order: -2, 1024 bytes)                                                                                    
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)                                                                          
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)                                                                           
Primary instruction cache 16kB, VIPT, 4-way, linesize 32 bytes.                                                                        
Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 32 bytes                                                                    
Writing ErrCtl register=0007fad8                                                                                                       
Readback ErrCtl register=0007fad8                                                                                                      
Memory: 57724k/65536k available (2181k kernel code, 7736k reserved, 374k data, 4484k init, 0k highmem)                                 
Hierarchical RCU implementation.                                                                                                       
NR_IRQS:256                                                                                                                            
console [ttyS0] enabled                                                                                                                
console [ttyS1] enabled, bootconsole disabled                                                                                          
console [ttyS1] enabled, bootconsole disabled                                                                                          
Calibrating delay loop... 221.69 BogoMIPS (lpj=443392)                                                                                 
Mount-cache hash table entries: 512                                                                                                    
NET: Registered protocol family 16                                                                                                     
MIPS: machine is Arcadyan ARV4518, SMC 7908A                                                                                           
regdomain: 0x0 --> 0x0                                                                                                                 
PCI: Probing PCI hardware on host bus 0.                                                                                               
IFXMips PCI mapped to 0xB7000000                                                                                                       
IFXMips PCI I/O mapped to 0xBAE00000                                                                                                   
bio: create slab <bio-0> at 0                                                                                                          
usbcore: registered new interface driver usbfs                                                                                         
usbcore: registered new interface driver hub                                                                                           
usbcore: registered new device driver usb                                                                                              
pci 0000:00:0e.0: BAR 0: assigned [mem 0x18000000-0x1800ffff]                                                                          
pci 0000:00:0e.0: BAR 0: set to [mem 0x18000000-0x1800ffff] (PCI address [0x18000000-0x1800ffff]                                       
Switching to clocksource MIPS                                                                                                          
NET: Registered protocol family 2                                                                                                      
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)                                                                         
TCP established hash table entries: 2048 (order: 2, 16384 bytes)                                                                       
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)                                                                               
TCP: Hash tables configured (established 2048 bind 2048)                                                                               
TCP reno registered                                                                                                                    
UDP hash table entries: 256 (order: 0, 4096 bytes)                                                                                     
UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)                                                                                
NET: Registered protocol family 1                                                                                                      
gptu: totally 6 16-bit timers/counters                                                                                                 
gptu: misc_register on minor 63                                                                                                        
gptu: succeeded to request irq 126                                                                                                     
gptu: succeeded to request irq 127                                                                                                     
gptu: succeeded to request irq 128                                                                                                     
gptu: succeeded to request irq 129                                                                                                     
gptu: succeeded to request irq 130                                                                                                     
gptu: succeeded to request irq 131                                                                                                     
squashfs: version 4.0 (2009/01/31) Phillip Lougher                                                                                     
Registering mini_fo version $Id$                                                                                                       
JFFS2 version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.                                         
msgmni has been set to 112                                                                                                             
io scheduler noop registered                                                                                                           
io scheduler deadline registered (default)                                                                                             
ttyS0 at MMIO 0xbe100400 (irq = 104) is a asc0                                                                                         
ttyS1 at MMIO 0xbe100c00 (irq = 111) is a asc1                                                                                         
eth0: using mac=00:26:4D:6A:49:D3                                                                                                      
ifxmips_mii: probed                                                                                                                    
eth0: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:00, irq=-1)                                                                
ifxmips_mii0: driver loaded!                                                                                                           
ifxmips_wdt: loaded                                                                                                                    
Registered led device: ifx:green:power                                                                                                 
Registered led device: ifx:red:power                                                                                                   
Registered led device: ifx:green:wlan                                                                                                  
Registered led device: ifx:green:adsl                                                                                                  
Registered led device: ifx:green:internet                                                                                              
Registered led device: ifx:red:internet                                                                                                
Registered led device: ifx:green:usb                                                                                                   
TCP westwood registered                                                                                                                
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:- preinit -                                                                                               
Press the [f] key and hit [enter] to enter failsafe mode                                                                               
- regular preinit -                                                                                                                    
- init -                                                                                                                               

Please press Enter to activate this console. IFXOS, Version 1.5.12 (c) Copyright 2009, Lantiq Deutschland GmbH

SCSI subsystem initialized
NET: Registered protocol family 8
NET: Registered protocol family 20
PPP generic driver version 2.4.2  
ip_tables: (C) 2000-2006 Netfilter Core Team
NET: Registered protocol family 24          
nf_conntrack version 0.5.0 (973 buckets, 3892 max)
IFX MEI Version 5.00.00

Infineon CPE API Driver version: DSL CPE API V3.24.4.4
Infineon Technologies ATM driver version 1.0.8
Infineon Technologies ATM (A1) firmware version 0.1
ifxmips_atm: ATM init succeed
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
gpio-buttons driver version 0.1.2
input: gpio-buttons as /devices/platform/gpio-buttons.0/input/input0



BusyBox v1.17.3 (2010-10-28 20:14:12 CEST) built-in shell (ash)
Enter 'help' for a list of built-in commands.

  _______                     ________        __
 |       |.-----.-----.-----.|  |  |  |.----.|  |_
 |   -   ||  _  |  -__|     ||  |  |  ||   _||   _|
 |_______||   __|_____|__|__||________||__|  |____|
          |__| W I R E L E S S   F R E E D O M
 KAMIKAZE (bleeding edge, r23691) ------------------
  * 10 oz Vodka       Shake well with ice and strain
  * 10 oz Triple sec  mixture into 10 shot glasses.
  * 10 oz lime juice  Salute!
 ---------------------------------------------------
root@OpenWrt:/#

usb doesn't work (I plugged an usb stick and it doesn't light up, nothing in dmesg).
dsl does something, though I don't know how to correctly set it up, I see this:

DSL_BSP_Showtime 875]: Datarate US intl = 759200, fast = 0

Edit: dsl works (once I modified the configuration, I'm not using yacom), but I don't know where to look at the negotiated speed, if that message means 759kpbs it's very poor (I get 15Mbps down and 800kbps up).

(Last edited by pippolippi on 31 Oct 2010, 19:51)

No wonder the usb doesnt work, there is no ehci or uhci module available for some reason.

That's because ngp's patch uses a different driver

call me stupid but i see no way for usb devices to be used without usbcore & usb2 related modules.

Datarate US intl = 759200 is upload speed, 759200 bps. Ii i recall correctly, you can get stats from somewhere in sysfs.

About usb: Is the dwc_otg module loaded?

Its not, and when i try to load it manually, it causes kernel oops (tho I'm using a little different hw, arv4519 that's been causing my previous problems)

can you post the oops? As far as I know, the only difference with ARV4519 is the fxo/isdn ports.

Here it is: http://pastebin.com/aG1C6zNc

Does it matter that I'm still using the older self-generated u-boot? As the firmware upload page from my ISP's firmware didnt accept that image as it was so I chopped it into a pieces & updated it manually.

@ngp, I checked out openwrt svn, applied your patches and tried to hack in ar8216 support in uboot (taking the code from the wnr2000 gpl sources) and the kernel (defining CONFIG_AR8216_PHY=y, don't know yet if that's enough).

What options should I select in make menuconfig?

I have selected these, are they the correct choices?

CONFIG_TARGET_ifxmips=y
CONFIG_TARGET_ifxmips_danube=y
CONFIG_TARGET_ifxmips_danube_None=y
CONFIG_TARGET_ROOTFS_INITRAMFS=y
CONFIG_TARGET_INITRAMFS_COMPRESSION_LZMA=y
CONFIG_UBOOT_TARGET="easy50712_DDR166M"
CONFIG_UBOOT_RAMBOOT=y
CONFIG_UBOOT_RAMBOOT_DDR_CONFIG="arv4518.conf"

@ngp, are you sure your patch for uboot is correct?

Applying ./patches/500-arv4518.patch using plaintext:
patching file common/Makefile
patching file drivers/pcmcia/Makefile
patching file drivers/usb/phy/Makefile
patching file Makefile
patching file common/Makefile
Hunk #1 FAILED at 127.
1 out of 1 hunk FAILED -- saving rejects to file common/Makefile.rej
patching file drivers/pcmcia/Makefile
Hunk #1 FAILED at 28.
1 out of 1 hunk FAILED -- saving rejects to file drivers/pcmcia/Makefile.rej
patching file drivers/usb/phy/Makefile
Hunk #1 FAILED at 23.
1 out of 1 hunk FAILED -- saving rejects to file drivers/usb/phy/Makefile.rej
patching file Makefile
Hunk #1 succeeded at 3431 with fuzz 2 (offset 16 lines).
Patch failed!  Please fix ./patches/500-arv4518.patch!

Edit: it turns out the file has the same patches 2 times. Maybe I applied your patch twice without realizing it.

(Last edited by pippolippi on 1 Nov 2010, 16:43)

Now I compiled my uboot (changing CONFIG_UBOOT_TARGET to "arv4518") but it does nothing once uploaded sad
It's 40k bigger than the one from ngp, and the file I added shouldn't add that much weight (the corresponding .o file is just 11K, not stripped).
In config.mk I changed TEXT_BASE to 0x80002000, is that my error?

Edit: I put back the original config.mk and it still doesn't boot. Maybe I did something wrong or selected the wrong options, that could explain the difference in size (ngp uboot is 153280, mine is 196608).

Edit2: I removed my (small) modification and the size is still 196608, and it doesn't boot

(Last edited by pippolippi on 1 Nov 2010, 19:11)

Hi,

There are three possible targets for uboot arv4518

1: arv4518 generates a image for writing to flash (normally at address 0xb0000000, can be changed by TEXT_BASE) It wont work because initializes the ddr memory controller (while actually running from ddr) It is used for replacing brnboot with u-boot

2: arv4518 with CONFIG_UBOOT_RAMBOOT=y (or arv4518_ramboot): It generates a image for running from ram (normally from addr 0xa0040000, can be overriden) This image is used for  uploading by uart after generating asc file by gct script.

3: arv4518_brnboot with CONFIG_UBOOT_RAMBOOT=n. Use this one. It generates a image for running from ram as second stage bootloader at 0x80002000.

By the way, If you are changing manually config.mk, set TEXT_BASE to 0x80002000 and #define CONFIG_SYS_RAMBOOT

I will review the patch for the rejects, but it applied cleanly last time I checked.

(Last edited by ngp on 1 Nov 2010, 19:14)

@Jokinen

I will take a look over the oops.   
About the firmware update: Maybe the signature is different, or maybe the image layout is completely different. can you extract the sixth file with sp700ex utility?

Yes! network works with my modifications:

(edit , but only partially, on one port tftp loading timed out, while on another it worked fine).

U-Boot 2010.03 (Nov 01 2010 - 19:27:41)

Board: Danube/Twinpass/Vinax-VE V1.5, DDR Speed 166 MHz, CPU Speed 333 MHz
DRAM:  64 MB
Flash:  8 MB
*** Warning - bad CRC, using default environment

Net:   lq_cpe_eth

Type "run flash_nfs" to mount root filesystem over NFS

Hit any key to stop autoboot:  0
ARV4518 => ping 192.168.2.101
Using lq_cpe_eth device
host 192.168.2.101 is alive

(Last edited by pippolippi on 1 Nov 2010, 19:44)

Ill try, but before I do anything I'd just like to thank you for your patience, its not easy to guide newbies like me.

Edit: It only extracts 5 files and just to mention - I have no need to keep the original brn loader.

(Last edited by Jokinen on 1 Nov 2010, 19:39)

Sorry, posts 151 to 150 are missing from our archive.