Support for D-link DSL-G225

HI All

I have a D-link DSL-G225 router and I would like to add support for these unit.

I have managed to obtain the open source firmware from a d-link website and now I would like to know how do i get the d-link firmware to mesh with Lede so i can build a firmware for my unit.

if someone can point me to a document or a post on how I can get this done?


Well,it is not as easy as you may think.
There is no one size fits all manual.

First step would be to open the device and take note of SoC,RAM,flash and any additional IC-s like switches,wireless drivers.

Hey robimarko

thank you for replying, I surely hope it is not easy, if success was easy everyone would be doing it.

OK, one important question about opening the device, do i use the mini blow torch or an axe to crack it open.

What i was hoping for is welcome to the clan tosser, read this and then come and ask questions at pit four at the interstellar gateway sho-left from where you are now

I take it the best source of advise would still be the following articles
and this one mainly because the address states "developer/start"
If there is more I need to read on please advise me, as I would not mind seeing this device added to the list of supported devices.

Well, you can read that and you can also check OpenWRT wiki for similar adding new device wiki.

But really opening the device to see what is in there and if it is even worth your time is the first thing.
After you know what is in there you can see if there are similar devices and you can check their code for hints

Ok jokes aside, maybe this is more useful than opening the box and straining my eyes to see little chips

Escape character is '^]'.
BCM963381 Broadband Router

======Console Bootup Messages======
<5>Linux version 3.4.11-rt19 (linshaoliang2@s54) (gcc version 4.6.2 (Buildroot 2011.11) ) #1 SMP PREEMPT Fri Jun 3 16:42:43 HKT 2016
<4>flash=GD25Q128 size=16MB id=0xc84018  sector=64k spiclk=50M
<4>HS Serial flash device: GD25Q128, id 0xc84018 sector 64KB size 16384KB
<4>963381REF1 prom init
<6>CPU revision is: 0002a081 (Broadcom BMIPS4350)
<4>DSL SDRAM reserved: 0x132000
<6>Determined physical RAM map:
<6> memory: 03ece000 @ 00000000 (usable)
<6>Initrd not found or empty - disabling initrd
<4>Zone PFN ranges:
<4>  DMA      0x00000000 -> 0x00001000
<4>  Normal   0x00001000 -> 0x00003ece
<4>Movable zone start PFN for each node
<4>Early memory PFN ranges
<4>    0: 0x00000000 -> 0x00003ece
<7>On node 0 totalpages: 16078
<7>free_area_init_node: node 0, pgdat 804f1430, node_mem_map 81000000
<7>  DMA zone: 32 pages used for memmap
<7>  DMA zone: 0 pages reserved
<7>  DMA zone: 4064 pages, LIFO batch:0
<7>  Normal zone: 94 pages used for memmap
<7>  Normal zone: 11888 pages, LIFO batch:1
<6>PERCPU: Embedded 7 pages/cpu @81083000 s5088 r8192 d15392 u32768
<7>pcpu-alloc: s5088 r8192 d15392 u32768 alloc=8*4096
<7>pcpu-alloc: [0] 0 [0] 1 
<4>Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 15952
<5>Kernel command line: ro noinitrd  irqaffinity=0
<6>PID hash table entries: 256 (order: -2, 1024 bytes)
<6>Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
<6>Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
<4>Primary instruction cache 64kB, VIPT, 4-way, linesize 16 bytes.
<4>Primary data cache 32kB, 2-way, VIPT, cache aliases, linesize 16 bytes
<6>Memory: 58220k/64312k available (3997k kernel code, 6092k reserved, 1001k data, 228k init, 0k highmem)
<6>Preemptible hierarchical RCU implementation.
<6>console [ttyS0] enabled
<6>Calibrating delay loop... 598.01 BogoMIPS (lpj=299008)
<6>pid_max: default: 32768 minimum: 301
<6>Mount-cache hash table entries: 512
<6>--Kernel Config--
<6>  SMP=1
<6>  PREEMPT=1
<4>Broadcom Logger v0.1 Jun  3 2016 16:29:12
<6>CPU revision is: 0002a081 (Broadcom BMIPS4350)
<4>Primary instruction cache 64kB, VIPT, 4-way, linesize 16 bytes.
<4>Primary data cache 32kB, 2-way, VIPT, cache aliases, linesize 16 bytes
<6>Brought up 2 CPUs
<6>NET: Registered protocol family 16
<4>pmc_init:PMC using DQM mode
<4>Flash not used for Auxillary File System
<4>registering PCI controller with io_map_base unset
<4>bcm63xx_pcie: applying serdes parameters
<4>registering PCI controller with io_map_base unset
<4>set pinmux 97 to 1
<4>set pinmux 96 to 1
<4>set pinmux 87 to 1
<4>set pinmux 86 to 1
<4>set pinmux 55 to 2
<4>set pinmux 56 to 2
<4>set pinmux 69 to 1
<4>set pinmux 68 to 1
<4>set pinmux 58 to 1
<4>set pinmux 53 to 2
<4>set pinmux 52 to 2
<4>set pinmux 51 to 2
<4>set pinmux 48 to 2
<4>set pinmux 43 to 2
<4>set pinmux 66 to 2
<4>set pinmux 54 to 5
<4>set pinmux 44 to 2
<4>set pinmux 64 to 5
<4>set pinmux 63 to 5
<4>set pinmux 67 to 2
<4>set pinmux 45 to 2
<4>set pinmux 60 to 2
<4>set pinmux 62 to 2
<4>set pinmux 59 to 2
<4>set pinmux 93 to 3
<4>set pinmux 92 to 3
<4>set pinmux 91 to 3
<4>set pinmux 90 to 3
<4>flashRateCtrl =0
<6>bio: create slab <bio-0> at 0
<5>SCSI subsystem initialized
<6>usbcore: registered new interface driver usbfs
<6>usbcore: registered new interface driver hub
<6>usbcore: registered new device driver usb
<6>PCI host bridge to bus 0000:00
<6>pci_bus 0000:00: root bus resource [mem 0x10600000-0x106fffff]
<6>pci_bus 0000:00: root bus resource [io  0x11700000-0x1170ffff]
<7>pci 0000:00:09.0: [14e4:6300] type 00 class 0x0c0310
<7>pci 0000:00:09.0: reg 10: [mem 0x1000c400-0x1000c4ff]
<7>pci 0000:00:0a.0: [14e4:6300] type 00 class 0x0c0320
<7>pci 0000:00:0a.0: reg 10: [mem 0x1000c300-0x1000c3ff]
<6>PCI host bridge to bus 0000:01
<6>pci_bus 0000:01: root bus resource [mem 0xa0000000-0xbfffffff]
<6>pci_bus 0000:01: root bus resource [??? 0x00000000 flags 0x0]
<7>pci 0000:01:00.0: [14e4:6338] type 01 class 0x060400
<7>pci 0000:01:00.0: PME# supported from D0 D3hot
<7>pci 0000:02:00.0: [14e4:a8db] type 00 class 0x028000
<7>pci 0000:02:00.0: reg 10: [mem 0x00000000-0x00007fff 64bit]
<7>pci 0000:02:00.0: supports D1 D2
<6>pci 0000:01:00.0: BAR 8: assigned [mem 0xa0000000-0xa00fffff]
<6>pci 0000:02:00.0: BAR 0: assigned [mem 0xa0000000-0xa0007fff 64bit]
<6>pci 0000:01:00.0: PCI bridge to [bus 02-02]
<6>pci 0000:01:00.0:   bridge window [mem 0xa0000000-0xa00fffff]
<4>PCI: Enabling device 0000:01:00.0 (0000 -> 0002)
<6>bcmhs_spi bcmhs_spi.1: master is unqueued, this is deprecated
<4>skbFreeTask created successfully
<4>BLOG v3.0 Initialized
<4>BLOG Rule v1.0 Initialized
<4>Broadcom IQoS v0.1 Jun  3 2016 16:39:04 initialized
<4>Broadcom GBPM v0.1 Jun  3 2016 16:39:05 initialized
<6>NET: Registered protocol family 8
<6>NET: Registered protocol family 20
<6>Switching to clocksource MIPS
<6>NET: Registered protocol family 2
<6>IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
<6>TCP established hash table entries: 2048 (order: 2, 16384 bytes)
<6>TCP bind hash table entries: 2048 (order: 2, 16384 bytes)
<6>TCP: Hash tables configured (established 2048 bind 2048)
<6>TCP: reno registered
<6>UDP hash table entries: 128 (order: 0, 4096 bytes)
<6>UDP-Lite hash table entries: 128 (order: 0, 4096 bytes)
<6>NET: Registered protocol family 1
<7>PCI: CLS 16 bytes, default 16
<4>init_bcm_tstamp: unhandled mips_hpt_freq=300000000, adjust constants in bcm_tstamp.c
<6>bcm_tstamp initialized, (hpt_freq=300000000 2us_div=300 2ns_mult=0 2ns_shift=0)
<6>squashfs: version 4.0 (2009/01/31) Phillip Lougher
<6>jffs2: version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
<6>fuse init (API version 7.18)
<6>msgmni has been set to 113
<6>io scheduler noop registered (default)
<6>brd: module loaded
<6>loop: module loaded
<4>bcm963xx_mtd driver
<4>File system address: 0xb8010100
<4>Registered device mtd:rootfs dev0 Address=0xb8010100 Size=9539584
<6>PPP generic driver version 2.4.2
<6>PPP BSD Compression module registered
<6>PPP Deflate Compression module registered
<6>NET: Registered protocol family 24
<6>usbcore: registered new interface driver cdc_ether
<6>usbcore: registered new interface driver cdc_acm
<6>cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
<6>usbcore: registered new interface driver usbserial
<6>usbcore: registered new interface driver usbserial_generic
<6>USB Serial support registered for generic
<6>usbserial: USB Serial Driver core
<6>usbcore: registered new interface driver ftdi_sio
<6>USB Serial support registered for FTDI USB Serial Device
<6>ftdi_sio: v1.6.0:USB FTDI Serial Converters Driver
<4>brcmboard: brcm_board_init entry
<4>set pinmux 63 to 4
<4>set pinmux 64 to 4
<4>set pinmux 54 to 4
<4>SES: LED GPIO 0x1 is enabled
<4>DYING GASP IRQ initialized 
<6>Serial: BCM63XX driver $Revision: 3.00 $
<6>Magic SysRq with Auxilliary trigger char enabled (type ^ # h for list of supported commands)
<6>ttyS0 at MMIO 0xb0000280 (irq = 8) is a BCM63XX
<6>ttyS1 at MMIO 0xb00002a0 (irq = 9) is a BCM63XX
<4>Total # RxBds=2812
<4>bcmPktDmaBds_init: Broadcom Packet DMA BDs initialized
<6>GACT probability NOT on
<6>Mirror/redirect action on
<6>u32 classifier
<6>    input device check on
<6>    Actions configured
<6>xt_time: kernel timezone is -0000
<6>TCP: cubic registered
<6>Initializing XFRM netlink socket
<6>NET: Registered protocol family 10
<6>IPv6 over IPv4 tunneling driver
<6>NET: Registered protocol family 17
<6>NET: Registered protocol family 15
<6>Initializing MCPD Module
<6>Ebtables v2.0 registered
<6>ebt_time registered
<6>ebt_ftos registered
<6>ebt_wmm_mark registered
<6>8021q: 802.1Q VLAN Support v1.8
<6>VFS: Mounted root (squashfs filesystem) readonly on device 31:0.
<6>Freeing unused kernel memory: 228k freed
<4>chipinfo: module license 'proprietary' taints kernel.
<4>Disabling lock debugging due to kernel taint
<4>brcmchipinfo: brcm_chipinfo_init entry
<4>bcmxtmrt: Broadcom BCM3381B0 ATM/PTM Network Device v0.6 Jun  3 2016 16:37:57
<4>Broadcom Ingress QoS Module  Char Driver v0.1 Jun  3 2016 16:34:05 Registered<243>
<4>Broadcom Ingress QoS ver 0.1 initialized
<4>BPM: tot_mem_size=67108864B (64MB), buf_mem_size <15%> =10066320B (9MB), num of buffers=4993, buf size=2016
<4>Broadcom BPM Module Char Driver v0.1 Jun  3 2016 16:34:04 Registered<244>
<4>NBUFF v1.0 Initialized
<4>Initialized fcache state
<4>Broadcom Packet Flow Cache  Char Driver v2.2 Jun  3 2016 16:34:06 Registered<242>
<4>Created Proc FS /procfs/fcache
<4>Broadcom Packet Flow Cache registered with netdev chain
<4>Broadcom Packet Flow Cache learning via BLOG enabled.
<4>flwStatsThread created
<4>Constructed Broadcom Packet Flow Cache v2.2 Jun  3 2016 16:34:06
<4>bcmxtmcfg: bcmxtmcfg_init entry
<4>adsl: adsl_init entry
<4>Broadcom BCM63381B0 Ethernet Network Device v0.1 Jun  3 2016 16:37:40
<4>ETH Init: Ch:0 - 200 tx BDs at 0xa2b02000
<4>ETH Init: Ch:0 - 1997 rx BDs at 0xa3914000
<4>dgasp: kerSysRegisterDyingGaspHandler: bcmsw registered 
<4>eth0: <Int sw port: 0> <Logical : 00> PHY_ID <0x00000001 : 0x01> MAC : 10:BE:F5:92:C1:0D
<4>eth1: <Int sw port: 1> <Logical : 01> PHY_ID <0x00000002 : 0x02> MAC : 10:BE:F5:92:C1:0D
<4>eth2: <Int sw port: 2> <Logical : 02> PHY_ID <0x00000003 : 0x03> MAC : 10:BE:F5:92:C1:0D
<4>eth3: <Int sw port: 3> <Logical : 03> PHY_ID <0x00000004 : 0x04> MAC : 10:BE:F5:92:C1:0D
<4>eth4: <Int sw port: 4> <Logical : 04> PHY_ID <0x02180018 : 0x18> MAC : 10:BE:F5:92:C1:0D
<4>Ethernet Auto Power Down and Sleep: Enabled
<4>  Chip WAN Only Port 00000000, Defined WAN Only Port 00000000, WAN Only Port Result: 0x00000000
<4>  Chip WAN Preffered Port 00000000, Defined WAN Preffered Port 00000000, WAN Preffered Port Result: 0x00000000
<4>  Chip LAN Only Port 00000000, Defined LAN Only Port 00000000, LAN Only Port Result: 0x00000000
<6>NComm TMS V6.80 Kernel Module loaded.
<6>ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
<4>PCI: Enabling device 0000:00:0a.0 (0000 -> 0002)
<7>ehci_hcd 0000:00:0a.0: setting latency timer to 64
<6>ehci_hcd 0000:00:0a.0: EHCI Host Controller
<6>ehci_hcd 0000:00:0a.0: new USB bus registered, assigned bus number 1
<4>ehci_hcd 0000:00:0a.0: Enabling legacy PCI PM
<6>ehci_hcd 0000:00:0a.0: irq 113, io mem 0x1000c300
<6>ehci_hcd 0000:00:0a.0: USB f.f started, EHCI 1.00
<6>hub 1-0:1.0: USB hub found
<6>hub 1-0:1.0: 1 port detected
<6>ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
<4>PCI: Enabling device 0000:00:09.0 (0000 -> 0002)
<7>ohci_hcd 0000:00:09.0: setting latency timer to 64
<6>ohci_hcd 0000:00:09.0: OHCI Host Controller
<6>ohci_hcd 0000:00:09.0: new USB bus registered, assigned bus number 2
<6>ohci_hcd 0000:00:09.0: irq 112, io mem 0x1000c400
<6>hub 2-0:1.0: USB hub found
<6>hub 2-0:1.0: 1 port detected
<6>usb 2-1: new full-speed USB device number 2 using ohci_hcd
<6>usbcore: registered new interface driver usblp
<6>Initializing USB Mass Storage driver...
<6>usb 2-1: USB disconnect, device number 2
<6>scsi0 : usb-storage 2-1:1.0
<6>usbcore: registered new interface driver usb-storage
<6>USB Mass Storage support registered.
<6>usbcore: registered new interface driver cdc_ncm
<6>usbcore: registered new interface driver 3g_modem
<6>USB Serial support registered for 3G_USB_modem
<6>usb 2-1: new full-speed USB device number 3 using ohci_hcd
<6>Initializing WLCSM Module
<6>WLCSM Module loaded successfully 
<6>scsi3 : usb-storage 2-1:1.2
<5>scsi 3:0:0:0: CD-ROM            HUAWEI   Mass Storage     2.31 PQ: 0 ANSI: 2
<4>sr0: scsi-1 drive
<6>cdrom: Uniform CD-ROM driver Revision: 3.20
<7>sr 3:0:0:0: Attached scsi CD-ROM sr0
<5>sr 3:0:0:0: Attached scsi generic sg0 type 5
<4>--SMP support
<4>wl: dsl_tx_pkt_flush_len=338
<4>wl: norm_wmark_tot=1417, pktc_wmark_tot=1417
<4>PCI: Enabling device 0000:02:00.0 (0000 -> 0002)
<4>wl: passivemode=1
<6>wl0: creating kthread wl0-kthrd
<4>wl: napimode=0
<4>initvars_cis_pci: Not CIS format
<4>Neither SPROM nor OTP has valid image
<4>wl:srom/otp not programmed, using main memory mapped srom info(wombo board)
<4>wl: ID=pci/2/0/
<4>wl: ID=pci/2/0/
<4>wl: loading /etc/wlan/bcm43217_map.bin
<4>srom rev:8
<4>wl: reading /etc/wlan/bcmcmn_nvramvars.bin, file size=32
<4>wl0: allocskbmode=1 currallocskbsz=256
<4>wl0: Broadcom BCM43227 802.11 Wireless Controller
<4>dgasp: kerSysRegisterDyingGaspHandler: wl0 registered 
<6>Broadcom 802.1Q VLAN Interface, v0.1
<4>brcm_otp_init entry
<4>Energy Efficient Ethernet: Enabled

###DumpSysInfo: now dump CMS information


#####Memory Info
Total MDM Shared Memory Region : 544KB
Shared Memory Usable           : 000429KB
Shared Memory in-use           : 000112KB
Shared Memory free             : 000316KB
Shared Memory allocs           : 296687
Shared Memory frees            : 294821
Shared Memory alloc/free delta : 001866

Heap bytes in-use     : 000024
Heap allocs           : 000855
Heap frees            : 000853
Heap alloc/free delta : 000002

###DumpSysInfo: First dump system information
======Version Info======
######kernel version######
Linux version 3.4.11-rt19 (linshaoliang2@s54) (gcc version 4.6.2 (Buildroot 2011.11) ) #1 SMP PREEMPT Fri Jun 3 16:42:43 HKT 2016
######wl version######
7.14 RC89.3303
wl0: Jun  3 2016 16:36:10 version
vendorid 0x14e4
deviceid 0x43a9
radiorev 0xe2057000
chipnum 0xa8d1
chiprev 0x1
chippackage 0x9
corerev 0x1e
boardid 0x5d6
boardvendor 0x14e4
boardrev P103
driverrev 0x70e59ce
ucoderev 0x3a02716
bus 0x1
phytype 0x4
phyrev 0x11
anarev 0x0
nvramrev 0
######xdsl version######
/bin/xdslctl version 1.2
ADSL PHY: AnnexA version - A2pvI041d2.d26b

======System Info======
38948.72 76536.63
system type             : 963381REF1
processor               : 0
cpu model               : Broadcom BMIPS4350 V8.1
BogoMIPS                : 598.01
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 32
extra interrupt vector  : no
hardware watchpoint     : no
ASEs implemented        :
shadow register sets    : 1
kscratch registers      : 0
core                    : 0
VCED exceptions         : not available
VCEI exceptions         : not available

processor               : 1
cpu model               : Broadcom BMIPS4350 V8.1
BogoMIPS                : 606.20
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 32
extra interrupt vector  : no
hardware watchpoint     : no
ASEs implemented        :
shadow register sets    : 1
kscratch registers      : 0
core                    : 0
VCED exceptions         : not available
VCEI exceptions         : not available

           CPU0       CPU1       
  0:     140863    1216228   BCM63xx  IPI
  7:   38948455   38948551   BCM63xx  timer
  8:          0       1042  BCM63xx_no_unmask  serial
 16:     755380          0  BCM63xx_no_unmask  dsl
 23:     618717          0  BCM63xx_no_unmask  brcm_23
 24:          0          0  BCM63xx_no_unmask  brcm_24
 25:          0          0  BCM63xx_no_unmask  brcm_25
 26:          0          0  BCM63xx_no_unmask  brcm_26
 36:    1089206          0   BCM63xx  wl0
 57:         40          0  BCM63xx_no_unmask  brcm_57
 69:          0          0  BCM63xx_no_unmask  brcm_69
 72:          0          0  BCM63xx_no_unmask  brcm_72
 73:          0          0  BCM63xx_no_unmask  brcm_73
112:   12723784          0   BCM63xx  ohci_hcd:usb2
113:          8          0   BCM63xx  ehci_hcd:usb1
117:          0          0   BCM63xx  restore_button
118:          2          0   BCM63xx  wps_button
121:          0          0   BCM63xx  wlan_button
ERR:          0
MemTotal:          58448 kB
MemFree:            1976 kB
Buffers:            5076 kB
Cached:            16728 kB
SwapCached:            0 kB
Active:            12876 kB
Inactive:          14856 kB
Active(anon):       5944 kB
Inactive(anon):        0 kB
Active(file):       6932 kB
Inactive(file):    14856 kB
Unevictable:          16 kB
Mlocked:               0 kB
SwapTotal:             0 kB
SwapFree:              0 kB
Dirty:                 0 kB
Writeback:             0 kB
AnonPages:          5940 kB
Mapped:             5824 kB
Shmem:                 0 kB
Slab:              20740 kB
SReclaimable:       1104 kB
SUnreclaim:        19636 kB
KernelStack:        1104 kB
PageTables:          624 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:       29224 kB
Committed_AS:      13728 kB
VmallocTotal:    1032116 kB
VmallocUsed:        7396 kB
VmallocChunk:     998896 kB
00000000-03ecdfff : System RAM
  00010000-003f762f : Kernel code
  003f7630-004f1e1f : Kernel data
1000c300-1000c3ff : ehci_hcd
1000c400-1000c4ff : ohci_hcd
10600000-106fffff : bcm63xx pci memory space
a0000000-bfffffff : bcm63xx pcie memory space
  a0000000-a00fffff : PCI Bus 0000:02
    a0000000-a0007fff : 0000:02:00.0

the ADSL chip has been rendered useless with a tiny hole in the chip, so if I am successful with the Lede load, I will take an angle grinder to the dsl port and cut it off, but as for the rest of the board it is working well.

I am not that in-experienced at this, my first was the linksys wrt54g unit, to which i added the mmc downgrade option as per OpenWRT forum and then politely bricked the unit and now i obtained this unit to play with

From what I can see there is no other device in LEDE using this SoC,altough there are ones using BCM63281 and DTS for BCM63381 is available
You can give it a try,but if wlan is also Broadcom support for it could be limited or non existant

Well from what I have read so far from the opensouce firmware i got from D-link, everything i need to make this work is there, i just need to get the files into Lede for a build
I may be picking up a few more of these units this weekend

From what i have read these unit have
dual core procs hopefully 400mhz
16mb/64mb memory
4 eth
1 wan
USB 2 or 3