Support Fritzbox 7490

Hello everyone!

I am trying to port lede to the Fritzbox 7490 which uses a similar chipset than the already supported 7360 SL.
Currently i am trying to the the serial console running and building an image.

I read that the adam2 bootloader supports booting directly from ram. see https://wiki.openwrt.org/doc/techref/bootloader/adam2

Anybody else working to get the device up and running?
Does anybody have experiences in booting from ram using adam2 (possible bricks,....)?

thx

3 Likes

Hi, did you get the device working with lede or openwrt?

Best Regards

Hi.

No, i stopped working on it because it is my production device :frowning:
I am now using freetz to customize the device.

Best regards

Hey, is this device supported yet?

https://forum.openwrt.org/t/support-fritzbox-7490/4112
This guy says it is using the same chipset as the 7360 sl?!

Thanks!

Hm.. What was your the problem? Did you build the image for the device?

There is no support for 7490 so far, the SOC and the related 7360 are, which might make adding support reasonably easy (no drivers for DECT though), but someone with the device still has to do the porting.

How to do the porting? I have multiple devices.

If you refer to DECT functionality in particular, the necessary drivers (and subsystem!) will probably have to be developed from scratch, with little to none reference to go by.

I don't need the DECT functionality, I just need the base system, no special features :slight_smile:

Look through the git history for the commits adding support for the 3370 and 7360, the 7490 should be reasonably similar.

from the wiki I cannot understand the status of the OpenWrt support...
is it working?

If the wiki does not explicitly state that it is supported, then it is not.

This still applies:

Hey, if it’s any help I’m willing to sponsor this by donating a 7490. Pm me if your interested.
(I’m also not worried about DECT functionality either)

well, I thought I'd give it a try and see if I could do this myself. Bare with me, as this is the first device I've attempted to add support for.

As a starting point, I am beginning on the excellent work of @danijeltudek (which is still being finalized before merge to master).

I can happily report that the 7362 kernel ramfs booted successfully on my 7490. :slight_smile:

The good:

  • it booted :slight_smile:
  • 2 cpus detected and initialized ok
  • 2 PHY devices detected

The bad (where I need to focus my efforts)

  • iw list isn't showing any output (not sure if this is normal for a minimal kernel ramfs image)
  • ethernet physical ports are a bit weird. tailing dmesg shows the following when I disconnect/reconnect ethernet cable:
    • "eth0 Port 4" = the physical "Lan1" connector on back of device
    • "eth0 port 2" = the physical "Lan2" connector
    • "eth0 port 1 = the physical "Lan4" connector
    • the physical "Lan3" connector never reports a link at all (also confirmed no link established with crossover cable and my PC directly connected.
  • memory only showing as 128Mb , I will need to expand to fill/use the full 256 (or 512, I have found conflicting information in my research).
  • lspci isn't available. Any suggestions on how to verify devices are detected before I bite the bullet and flash an image? Suggestions on any other useful modules to include in the kernel ramfs image to aid testing/validation?

Very loosely, my plan currently is to:

  1. finish verifying all devices get detected
  2. Identify the sizing required for the image (will probably follow similar convention to @danijeltudek in 7362
  3. get upto speed with the DTS files
  4. figure out the next build/testing feedback loop should be:
    • what steps can I bypass when recompiling each image ? Obviously skipping the toolchain will save enormous amounts of time. what is the "minimal clean" needed before building another image.

Any tips or insights on what else to verify/test next would be appreciated.

(and apologies for the somewhat rambling post..)

2 Likes

This is due to no WiFi card connected to the Lantiq chip. The 7490 are in fact two routers on one PCB with a QCA9558 linked to the Lantiq via Ethernet. It handles both WiFi interfaces (the integrated one and a QCA9880.

This might also be the reason for the differing claims of RAM size. You can see the RAM and both CPUs on this picture: https://boxmatrix.info/w/images/4/43/FRITZ!Box_7490-Image37.jpg

Best wishes
David

3 Likes

Download AVM's kernel source here:
http://osp.avm.de/fritzbox/fritzbox-7490/source-files-FRITZ.Box_7490-07.01.tar.gz

Take a look at my OpenWrt device tree for 7362, compare it to 7360, and compare both to AVM's device trees for HW 183 (7360), 185 (7490) and 203 (7362). You'll find all GPIO pins and their default states there.

Regarding the build process, if you want a clean build, use make clean. It keeps the toolchain. For quick kernel development, use make target/linux/install. Don't forget -jXX option for multithreaded build. I use -j33 on my 32-thread development machine.

2 Likes

Hi, nice to hard!
Is there a git repo for this?

Thanks!

It's in this pull request: https://github.com/openwrt/openwrt/pull/1742

Keep in mind that more work is needed before it'll be accepted, but it can be used as a reference to get 7490 to boot, at least.

Made the first named 7490 image , and device still booted which is good. In my searches, it seems that there is no lspci binary available for openwrt (which has always been my goto for checking hardware). Is doing a diff between the various /proc files the right way to tell whats working and whats not?

proc/cpuinfo

cpuinfo under openwrt
root@OpenWrt:/# cat /proc/cpuinfo 
system type             : xRX200 rev 1.2
machine                 : AVM FRITZ!Box 7490
processor               : 0
cpu model               : MIPS 34Kc V5.6
BogoMIPS                : 332.54
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 16
extra interrupt vector  : yes
hardware watchpoint     : yes, count: 4, address/irw mask: [0x0ffc, 0x0ffc, 0x0ffb, 0x0ffb]
isa                     : mips1 mips2 mips32r1 mips32r2
ASEs implemented        : mips16 dsp mt
shadow register sets    : 1
kscratch registers      : 0
package                 : 0
core                    : 0
VPE                     : 0
VCED exceptions         : not available
VCEI exceptions         : not available

processor               : 1
cpu model               : MIPS 34Kc V5.6
BogoMIPS                : 333.82
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 16
extra interrupt vector  : yes
hardware watchpoint     : yes, count: 4, address/irw mask: [0x0ffc, 0x0ffc, 0x0ffb, 0x0ffb]
isa                     : mips1 mips2 mips32r1 mips32r2
ASEs implemented        : mips16 dsp mt
shadow register sets    : 1
kscratch registers      : 0
package                 : 0
core                    : 0
VPE                     : 0
VCED exceptions         : not available
VCEI exceptions         : not available

cpuinfo under oem 7.01
system type             : VR9
machine                 : Unknown
processor               : 0
cpu model               : MIPS 34Kc V5.6
BogoMIPS                : 331.77
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 16
extra interrupt vector  : yes
hardware watchpoint     : yes, count: 4, address/irw mask: [0x0ffc, 0x0ffc, 0x0ffb, 0x0ffb]
isa                     : mips1 mips2 mips32r1 mips32r2
ASEs implemented        : mips16 dsp mt
shadow register sets    : 1
kscratch registers      : 0
core                    : 0
VPE                     : 0
VCED exceptions         : not available
VCEI exceptions         : not available

mips-options: 0x006d638b icache.flags 0x00000000 dcache.flags 0x00000004 isa_level 0x00000063 ases 00000031
processor               : 1
cpu model               : MIPS 34Kc V5.6
BogoMIPS                : 250.67
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 16
extra interrupt vector  : yes
hardware watchpoint     : yes, count: 4, address/irw mask: [0x0ffc, 0x0ffc, 0x0ffb, 0x0ffb]
isa                     : mips1 mips2 mips32r1 mips32r2
ASEs implemented        : mips16 dsp mt
shadow register sets    : 1
kscratch registers      : 0
core                    : 0
VPE                     : 1
VCED exceptions         : not available
VCEI exceptions         : not available

mips-options: 0x006d638b icache.flags 0x00000000 dcache.flags 0x00000004 isa_level 0x00000063 ases 00000031

proc/devices

devices under openwrt
root@OpenWrt:/# cat /proc/devices 
Character devices:
  1 mem
  5 /dev/tty
  5 /dev/console
  5 /dev/ptmx
 10 misc
 13 input
 90 mtd
108 ppp
109 drv_dsl_cpe_api
128 ptm
136 pts
180 usb
189 usb_device
252 mei_cpe
253 ttyLTQ
254 gpiochip

Block devices:
 31 mtdblock
254 ubiblock
259 blkext

devices under oem7.01
Character devices:
  1 mem
  2 pty
  3 ttyp
  4 /dev/vc/0
  4 tty
  4 ttyS
  5 /dev/tty
  5 /dev/console
  5 /dev/ptmx
  7 vcs
 10 misc
 13 input
 68 capi_oslib
 81 switch_api
 89 i2c
 90 mtd
128 ptm
136 pts
180 usb
189 usb_device
231 userman_url
232 kdsldptrace
233 kdsld_misc
234 kdsld_traffic
235 kdsld_user
236 kdsld
237 dect_io
238 dsl_vr9
239 mei_vr9
240 ifx_gpio
241 ifx_rcu
242 led
243 tffs
244 ifx_pmu
245 ifx_ts
246 ifx_cgu
247 ifx_pmcu
248 debug
249 avm_event
250 ifx_dma_core
251 watchdog
252 avm_power
253 avm_net_trace
254 rtc

Block devices:
259 blkext
  7 loop
 31 mtdblock
 43 nbd

proc/meminfo

Meminfo under openwrt
root@OpenWrt:/# cat /proc/meminfo 
MemTotal:         252980 kB
MemFree:          231064 kB
MemAvailable:     206900 kB
Buffers:               0 kB
Cached:            10260 kB
SwapCached:            0 kB
Active:             7228 kB
Inactive:           3896 kB
Active(anon):       7228 kB
Inactive(anon):     3896 kB
Active(file):          0 kB
Inactive(file):        0 kB
Unevictable:           0 kB
Mlocked:               0 kB
SwapTotal:             0 kB
SwapFree:              0 kB
Dirty:                 0 kB
Writeback:             0 kB
AnonPages:           896 kB
Mapped:             1720 kB
Shmem:             10260 kB
Slab:               4804 kB
SReclaimable:        824 kB
SUnreclaim:         3980 kB
KernelStack:         368 kB
PageTables:          180 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:      126488 kB
Committed_AS:      13132 kB
VmallocTotal:    1048372 kB
VmallocUsed:           0 kB
VmallocChunk:          0 kB

Meminfo under 7.01
MemTotal:         239360 kB
MemFree:          126164 kB
Buffers:           14044 kB
Cached:            59168 kB
SwapCached:            0 kB
Active:            22480 kB
Inactive:          60284 kB
Active(anon):      15764 kB
Inactive(anon):     1516 kB
Active(file):       6716 kB
Inactive(file):    58768 kB
Unevictable:        6060 kB
Mlocked:            6060 kB
SwapTotal:             0 kB
SwapFree:              0 kB
Dirty:                 0 kB
Writeback:             0 kB
AnonPages:         15628 kB
Mapped:            13800 kB
Shmem:              3200 kB
Slab:              15648 kB
SReclaimable:       3528 kB
SUnreclaim:        12120 kB
KernelStack:        1568 kB
PageTables:          532 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:      119680 kB
Committed_AS:      34432 kB
VmallocTotal:    1048308 kB
VmallocUsed:        1384 kB
VmallocChunk:    1008724 kB

Still Todo; Ethernet ports to physical port mappings are still wonky. I did try changing ../../../../target/linux/lantiq/base-files/etc/board.d/02_network and specifying different numbering - but it didn't seem to have any effect.

02_network
+avm,fritz7490)
+        annex="a"
+        lan_mac=$(fritz_tffs -n maca -i $(find_mtd_part "tffs (1)"))
+        wan_mac=$(fritz_tffs -n macdsl -i $(find_mtd_part "tffs (1)"))
+        ucidef_add_switch "switch0" \
+                "1:lan:1" "2:lan:2" "3:lan:3" "4:lan:4" "6t@eth0"
+        ;;
1 Like

There should be one in the pciutils package, or find the source package at feeds/packages/utils/pciutils in the OpenWrt tree with the packages feed.