User Tools

Site Tools


inbox:adsl_support

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Previous revision
inbox:adsl_support [2013/07/13 08:25]
inbox:adsl_support [2016/08/18 23:03] (current)
dpeddi [External Links]
Line 1: Line 1:
 +====== BCM63xx ADSL Support on Linux kernel 2.6.8.1 ======
 +| {{:​meta:​icons:​tango:​dialog-information.png?​nolink}} | → [[doc/​hardware/​soc/​soc.broadcom.bcm63xx]] |
 +| ::: | → [[toh/​davolink/​dv-2020|Davolink DV-2020]] |
 +| ::: | FYI: Linux kernel **2.6.8.1** was released on **2004-Aug-14**;​ this is not **//​old//​**,​ this is **//​ancient//​** (//see [[wp>​Linux_kernel#​Maintenance]]//​) |
 +
 +I have recently begun compiling and adapting the code found at [[https://​forum.openwrt.org/​viewtopic.php?​pid=120035#​p120035]] and testing it on a [[toh/​davolink/​dv-2020]] platform.
 +
 +First results are promising just now managed to compile and install the drivers.
 +
 +===== Kernel Modules =====
 +
 +{{:​media:​bcm63xx_adsl_kmods.png|}}
 +
 +
 +
 +===== Setup Manual WAN Connection =====
 +
 +Example script below sets up regular wan connection, just like **cfm** does but without the overhead.
 +
 +<code perl>
 +# minimal script to start IPoEoATM
 +#
 +# Using binary drivers from dv20xx_DV2010_SIP_ANNEX_A.1.05_consumer.tar.gz
 +#
 +# adslctl version 1.0                                                             
 +# ADSL PHY: AnnexA version - A2pB022f.d19e ​  
 +# atmctl version 1.1                                                              ​
 +
 +# Load responsible kernel modules
 +insmod /​lib/​modules/​2.6.8.1/​extra/​atmapi.ko
 +insmod /​lib/​modules/​2.6.8.1/​extra/​blaa_dd.ko
 +insmod /​lib/​modules/​2.6.8.1/​extra/​adsldd.ko
 +#insmod /​lib/​modules/​2.6.8.1/​extra/​bcmprocfs.ko
 +
 +# ADSL link up: ADSL2+ (llc encapsulation)
 +adslctl start --mod a --bitswap on --sra off --lpair i**
 +adslctl connection --up
 +#adslctl --version
 +
 +# ATM setup
 +atmctl start --pqs 125
 +atmctl operate intf --state 0 enable
 +#atmctl operate tdte --show
 +atmctl operate vcc --add 0.8.35 aal5 1 llcencaps --addq 0.8.35 300 1
 +
 +# PVC emulation
 +pvc2684d &
 +pvc2684ctl -a -v 0.8.35 &
 +
 +# Bring interface up
 +ifconfig nas_8_35 hw ether 00:​15:​66:​66:​66:​66
 +ifconfig nas_8_35 0.0.0.0
 +
 +udhcpc -i nas_8_35 &
 +
 +
 +# Cruft for the bcm cripled version dhcpc (not needed whan using regular udhcpcd of busybox)
 +#
 +#​bcmprocfs_ioctl creates symbolic link from /​proc/​var/​fyi/​wan/<​src>​ -> /​proc/​var/​fyi/​wan/<​dst>,​ see note below
 +#​bcmprocfs_ioctl .ppp0 nas_8_35
 +#mkdir -p /​var/​fyi/​sys
 +#dhcpc -i nas_8_35 &
 +</​code>​
 +
 +Note: **bcmprocfs_ioctl** is defined in [[inbox/​bcmprocfs]]
 +
 +===== ROADMAP ☺ =====
 +
 +  - <​del>​Get ADSL working with the 2.8.1 vendor distribution (davolink dv2020) without aid of cfm</​del>​ **DONE**
 +    * Sanitize the build system. Kconfig support. ect
 +    * Already fixed some initialization and potential buffer overflows. (you see clearly the drawbacks of closed source code: horror, horror, horror...)
 +  - Sanitize the driver code
 +    * Possibly convert the .cpp stuf to regular C.
 +  - Look at userspace apps atmctl / adslctl
 +    * Most of the support is now in kernel space part of it can be moved to userspace.
 +  - Openwrt integration,​ support for kernel 3.x
 +
 + 
 +
 +===== Feel free to add tips and tricks. =====
 +
 +...
 +
 +==== External Links ====
 +
 +[[http://​bcm63xx.sipsolutions.net/​Specification]] Attempt on writing a specification from the ground up. -> dead link (2016-08-18)
 +
 +[[http://​huaweihg612hacking.wordpress.com]] Very nice collection of useful bcm63xx information. -> dead link (2016-08-18)
 +
 +[[http://​www.pms.ifi.lmu.de/​mitarbeiter/​ohlbach/​multimedia/​IT/​IBMtutorial/​3376c213.html]] ATM tutorial.
 +
 +[[https://​github.com/​cubieb/​hg556a_source/​tree/​master/​bcmdrivers/​broadcom/​char/​adsl/​bcm96358 source for bcm6348/​58]]
 +
 +{{tag>​wip bcm63xx ADSL}}