Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-12 Thread Yeoh Chun Yeow
Hi, Peter, Thanks for you explanation. I have learned some insights on how the PHY/MAC works and MII. FYI, the patch works. I have tested with following /etc/config/network to send out the tagged packet: config 'switch' option 'name' 'eth1' option 'reset' '1' option 'enab

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-12 Thread Peter Lebbing
Hi, I hopefully have finished the two versions of the driver. One effectively only supports the M model (though it detects and initialises the FC model), and the second experimental one adds VLAN support for the FC model. I don't have the time right now to do the official patch submission. But at

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-12 Thread Peter Lebbing
On 12/04/11 09:15, Yeoh Chun Yeow wrote: > Unfortunately, the driver that you provided not able to detect the > switch correctly "ADM6996FC PHY detected". > > I have observed the following: > eth0: PHY overlaps ADM6996, providing fixed PHY 14. > eth1: PHY overlaps ADM6996, providing fixed PHY 10.

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-12 Thread Yeoh Chun Yeow
Unfortunately, the driver that you provided not able to detect the switch correctly "ADM6996FC PHY detected". I have observed the following: eth0: Atheros AG71xx at 0xb900, irq 4* eth0: PHY overlaps ADM6996, providing fixed PHY 14.* eth0: connected to PHY at ag71xx-mdio:14 [uid=1027, driv

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-11 Thread David Goodenough
On Monday 11 April 2011, Peter Lebbing wrote: > On 11/04/11 11:08, Yeoh Chun Yeow wrote: > > However, even the board is up without Ethernet cable connecting to the > > LAN port 1 or port 0, the message "eth1: link up (100Mbps/Full duplex) > > is already printed there. > > Yeah, it's still not comp

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-11 Thread Peter Lebbing
On 11/04/11 11:08, Yeoh Chun Yeow wrote: > However, even the board is up without Ethernet cable connecting to the LAN > port 1 or port 0, the message "eth1: link up (100Mbps/Full duplex) is > already printed there. Yeah, it's still not completely clear to me how these ports are all connected. If

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-11 Thread Yeoh Chun Yeow
Dear Jonas, After patching the patch, the messages ""Trying 100/FULL, Trying 10/HALF, Trying 10/HALF" disappear during startup. However, even the board is up without Ethernet cable connecting to the LAN port 1 or port 0, the message "eth1: link up (100Mbps/Full duplex) is already printed there. T

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-10 Thread Peter Lebbing
On 08/04/11 03:20, Yeoh Chun Yeow wrote: > You have any clue which datasheet for FC chip should be referred to. For > me, it seems that it is not similar to F chip or not totally same with M > chip. I'd love to have a datasheet for the FC chip, but I can't find it. It would appear the M is an en

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-08 Thread Yeoh Chun Yeow
Yes, I am using the backfire version and will report my finding once I do it. On Fri, Apr 8, 2011 at 11:00 PM, Jonas Gorski < jonas.gorski+open...@gmail.com> wrote: > On 6 April 2011 16:18, Yeoh Chun Yeow wrote: > > Hi, Jonas, > > UBNT RS has two ports connected to eth1, port 0 and port 1. If yo

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-08 Thread Jonas Gorski
On 6 April 2011 16:18, Yeoh Chun Yeow wrote: > Hi, Jonas, > UBNT RS has two ports connected to eth1, port 0 and port 1. If you connect > your Ethernet cable to port 0 without first connecting Ethernet cable to > port 1, it won't work. You will see a lot of messages "Trying 100/FULL, > Trying 10/HA

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread Yeoh Chun Yeow
Hi, Peter You have any clue which datasheet for FC chip should be referred to. For me, it seems that it is not similar to F chip or not totally same with M chip. Regards, Chun Yeow On Thu, Apr 7, 2011 at 10:54 PM, Peter Lebbing wrote: > > > It works as I described on the M chip. It was suggested

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread Peter Lebbing
>> Watch out for the primary VLAN ID; "pvid" property of the port. "swconfig >> dev eth1 show" is your friend. The PVID might not always be what you >> expect. Seeing where untagged packets go is something that needs to be >> tested for the FC chip. The M chip is configured such that untagged pa

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread Yeoh Chun Yeow
> > But it is a curious setup. Did you do it just to test the functionality? > Yes, mainly for testing purpose. > > Good to hear a more usual setup does work. I assume this is with the patch > you > sent earlier? Yes, using the patch I posted before. > In that case the common case where a por

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread Yeoh Chun Yeow
> > So the two ports 0 and 1 are attached to the switch chip ports with those > numbers? > > UBNT RS has three port. From the Left is LAN port 1, LAN port 0 and WAN port. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread David Goodenough
On Thursday 07 April 2011, Peter Lebbing wrote: > On 06/04/11 16:18, Yeoh Chun Yeow wrote: > > UBNT RS has two ports connected to eth1, port 0 and port 1. If you > > connect your Ethernet cable to port 0 without first connecting Ethernet > > cable to port 1, it won't work. You will see a lot of mes

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread Peter Lebbing
On 05/04/11 08:52, Yeoh Chun Yeow wrote: > Untagged packet receive by port 1 is drop. But VLAN 1 and VLAN 2 tagged > packet for port 0 is working perfertly. > > config 'switch_vlan' > option 'device' 'eth1' > option 'vlan' '1' > option 'vid' '1' > option 'ports' '0t

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-07 Thread Peter Lebbing
On 06/04/11 16:18, Yeoh Chun Yeow wrote: > UBNT RS has two ports connected to eth1, port 0 and port 1. If you > connect your Ethernet cable to port 0 without first connecting Ethernet > cable to port 1, it won't work. You will see a lot of messages "Trying > 100/FULL, Trying 10/HALF, Trying 10/HALF

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-06 Thread Yeoh Chun Yeow
Hi, Jonas, UBNT RS has two ports connected to eth1, port 0 and port 1. If you connect your Ethernet cable to port 0 without first connecting Ethernet cable to port 1, it won't work. You will see a lot of messages "Trying 100/FULL, Trying 10/HALF, Trying 10/HALF". Once you connect port 1 with Ether

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-06 Thread Jonas Gorski
On 5 April 2011 08:52, Yeoh Chun Yeow wrote: > Any reason why the first configuration failed? > config 'switch_vlan' >     option 'ports' '0t 1 5t' > > config 'switch_vlan' >     option 'ports' '0t 1 5t' Generally you can't have a port untagged for more than one VLAN, for all others it h

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-04 Thread Yeoh Chun Yeow
Untagged packet receive by port 1 is drop. But VLAN 1 and VLAN 2 tagged packet for port 0 is working perfertly. config 'switch_vlan' option 'device' 'eth1' option 'vlan' '1' option 'vid' '1' option 'ports' '0t 1 5t' config 'switch_vlan' option 'device' 'eth

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-04 Thread Yeoh Chun Yeow
> > > Interesting find, thanks! Can the port still send *untagged* packets as > well, if > you configure untagged membership? When I wrote the driver, I think I > explicitly > chose not to set this bit, and it was unneeded for my M chip. Perhaps it > means > "ALWAYS send tagged packets", but I woul

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-04 Thread Peter Lebbing
On 04/04/11 12:59, Yeoh Chun Yeow wrote: > Hi, Peter and David, > > I add the following patch and VLAN tagging working fine for UBNT RS: > Interesting find, thanks! Can the port still send *untagged* packets as well, if you configure untagged membership? When I wrote the driver, I think I explicit

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-04 Thread Yeoh Chun Yeow
Hi, Peter and David, I add the following patch and VLAN tagging working fine for UBNT RS: --- ./target/linux/generic-2.6/files/drivers/net/phy/adm6996.c 2011-03-29 16:24:22.869595814 +0800 +++ ./build_dir/linux-ar71xx/linux-2.6.32.27/drivers/net/phy/adm6996.c 2011-04-04 18:32:14.188937710 +0800

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Yeoh Chun Yeow
David, Can you send me the datasheet. Thanks On Fri, Apr 1, 2011 at 5:34 PM, David Goodenough < david.goodeno...@linkchoose.co.uk> wrote: > On Friday 01 April 2011, Peter Lebbing wrote: > > On 01/04/11 03:27, Yeoh Chun Yeow wrote: > > > Ok I found the script. > > > > > > read-all-adm output atta

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread John Crispin
Hi Peter, i just dug out a board with the I version and wanted to also run the test script on this type. could oyu resent the all in one patch to the list so patchwork grabs the full version, currently only the fix is listed in patchwork http://patchwork.midlink.org/patch/576/ thx, John On 01/

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Peter Lebbing
On 01/04/11 11:52, Yeoh Chun Yeow wrote: > Don't think that VLAN tagging is working. > > TCP dump results are shown below: > > # tcpdump -eni eth2 > tcpdump: verbose output suppressed, use -v or -vv for full protocol decode > listening on eth2, link-type EN10MB (Ethernet), capture size 96 bytes >

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Yeoh Chun Yeow
Don't think that VLAN tagging is working. TCP dump results are shown below: # tcpdump -eni eth2 tcpdump: verbose output suppressed, use -v or -vv for full protocol decode listening on eth2, link-type EN10MB (Ethernet), capture size 96 bytes 19:00:21.462159 00:15:6d:c3:81:b1 > ff:ff:ff:ff:ff:ff, e

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread David Goodenough
On Friday 01 April 2011, Yeoh Chun Yeow wrote: > Just to confirm adm6996fc is similar to adm6996m or adm6996f. I always thought the F and FC were more similar the the M, but I have no evidence for that. David > > On Fri, Apr 1, 2011 at 5:34 PM, David Goodenough < > > david.goodeno...@linkchoose.

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Yeoh Chun Yeow
Just to confirm adm6996fc is similar to adm6996m or adm6996f. On Fri, Apr 1, 2011 at 5:34 PM, David Goodenough < david.goodeno...@linkchoose.co.uk> wrote: > On Friday 01 April 2011, Peter Lebbing wrote: > > On 01/04/11 03:27, Yeoh Chun Yeow wrote: > > > Ok I found the script. > > > > > > read-all

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread David Goodenough
On Friday 01 April 2011, Peter Lebbing wrote: > On 01/04/11 03:27, Yeoh Chun Yeow wrote: > > Ok I found the script. > > > > read-all-adm output attach. > > Thanks very much. It's not vital, but if you still have the setup ready, > could you remove the VLAN related config from your /etc/config/net

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Yeoh Chun Yeow
Attach is the regs. config interface loopback option ifname lo option protostatic option ipaddr 127.0.0.1 option netmask 255.0.0.0 config interface lan option ifname eth1 option type bridge option protostatic optio

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Peter Lebbing
On -10/01/37 20:59, Yeoh Chun Yeow wrote: > It seems that ADM6996FC is different from ADM6996M. How to ensure the > port get tagged? Is this by simply modifying Configuration register Bit 4? It's a lot more involved on the M model. A whole bunch of bits need to be changed before it works as one wo

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-04-01 Thread Peter Lebbing
On 01/04/11 03:27, Yeoh Chun Yeow wrote: > Ok I found the script. > > read-all-adm output attach. Thanks very much. It's not vital, but if you still have the setup ready, could you remove the VLAN related config from your /etc/config/network and run the script again? It would be helpful if the dr

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Yeoh Chun Yeow
Ok I found the script. read-all-adm output attach. On Fri, Apr 1, 2011 at 9:19 AM, Yeoh Chun Yeow wrote: > Please send me the script that you mentioned > > I have run the following: > > :~# swconfig dev eth1 vlan 2 set ports '0 1 2 3t 4t 5t' > :~# swconfig dev eth1 get addr > 0 > :~# swconfig de

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Yeoh Chun Yeow
Please send me the script that you mentioned I have run the following: :~# swconfig dev eth1 vlan 2 set ports '0 1 2 3t 4t 5t' :~# swconfig dev eth1 get addr 0 :~# swconfig dev eth1 get data 65535 dmesg Infineon ADM6996 ag71xx-mdio:10: set_pvid port 0 vlan 2 Infineon ADM6996 ag71xx-mdio:10: set_

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Peter Lebbing
On -10/01/37 20:59, John Crispin wrote: > can you post a link to the patch ? Also using pointers about patchwork use recently posted here, I unearthed my patch: http://patchwork.midlink.org/patch/574/ Apparently patchwork thought that my one-line fix superseded a 666-line patch file :). That wo

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Peter Lebbing
On 31/03/11 17:08, Yeoh Chun Yeow wrote: > Yes, I will do that. By the way, what should I check with debug info? Nothing needs to be checked. But the read-all-adm script uses a facility in the driver that is only compiled in when DEBUG is enabled. It reads the contents of all addressable register

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Yeoh Chun Yeow
Yes, I will do that. By the way, what should I check with debug info? On Thu, Mar 31, 2011 at 8:53 PM, David Goodenough < david.goodeno...@linkchoose.co.uk> wrote: > Well the first problem is to detect that this is an FC not an M. This code > was written on the assumption (as I understand it) th

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread David Goodenough
Well the first problem is to detect that this is an FC not an M. This code was written on the assumption (as I understand it) that it would only work on the M, but I had a suspicion that it would also work on the FC but I could not get a kernel built to test it (my bad). We obviously can not si

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Yeoh Chun Yeow
It seems that ADM6996FC is different from ADM6996M. How to ensure the port get tagged? Is this by simply modifying Configuration register Bit 4? On Thu, Mar 31, 2011 at 3:27 PM, Yeoh Chun Yeow wrote: > > > On Wed, Mar 30, 2011 at 10:52 PM, Yeoh Chun Yeow > wrote: > >> Dear all, >> >> I am able t

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-31 Thread Yeoh Chun Yeow
On Wed, Mar 30, 2011 at 10:52 PM, Yeoh Chun Yeow wrote: > Dear all, > > I am able to get the patch works by adding the following in mach-ubnt.c: > > ar71xx_eth1_data.phy_mask = UBNT_RS_LAN_PHYMASK > > However, there is two issues here: > 1. RouterStation has two ports on ETH1. One port can only be

[OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread Yeoh Chun Yeow
Dear all, I am able to get the patch works by adding the following in mach-ubnt.c: ar71xx_eth1_data.phy_mask = UBNT_RS_LAN_PHYMASK However, there is two issues here: 1. RouterStation has two ports on ETH1. One port can only be activated after the other port is connected with cable. If this port

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread Florian Fainelli
On Wednesday 30 March 2011 10:41:10 John Crispin wrote: > can you post a link to the patch ? Thread starts here: https://lists.openwrt.org/pipermail/openwrt-devel/2011-January/009100.html -- Florian ___ openwrt-devel mailing list openwrt-devel@lists.ope

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread John Crispin
https://lists.openwrt.org/pipermail/openwrt-devel/2011-January/009100.html this is assume On 30/03/11 10:55, John Crispin wrote: > yes and the archive can be linked to :) > > On 30/03/11 10:51, David Goodenough wrote: >> Its not on a web site, just in the archive of this mail-list. >> >> David >

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread John Crispin
yes and the archive can be linked to :) On 30/03/11 10:51, David Goodenough wrote: > Its not on a web site, just in the archive of this mail-list. > > David > > On Wednesday 30 March 2011, John Crispin wrote: >> can you post a link to the patch ? >> >> On 30/03/11 10:34, David Goodenough wrote:

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread David Goodenough
Its not on a web site, just in the archive of this mail-list. David On Wednesday 30 March 2011, John Crispin wrote: > can you post a link to the patch ? > > On 30/03/11 10:34, David Goodenough wrote: > > On Wednesday 30 March 2011, Yeoh Chun Yeow wrote: > >> Dear all, > >> > >> Any one has trie

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread John Crispin
can you post a link to the patch ? On 30/03/11 10:34, David Goodenough wrote: > On Wednesday 30 March 2011, Yeoh Chun Yeow wrote: >> Dear all, >> >> Any one has tried the patch from Peter Lebbing on VLAN tag on UBNT >> RouterStation platform and get it work properly. >> >> Regards, >> Chun Yeow >

Re: [OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-30 Thread David Goodenough
On Wednesday 30 March 2011, Yeoh Chun Yeow wrote: > Dear all, > > Any one has tried the patch from Peter Lebbing on VLAN tag on UBNT > RouterStation platform and get it work properly. > > Regards, > Chun Yeow I am afraid that I have difficulty building the kernel to try it on an ADM6996FC (on th

[OpenWrt-Devel] 802.1Q VLAN support for Infineon ADM6996 switch chip for UBNT RouterStation

2011-03-29 Thread Yeoh Chun Yeow
Dear all, Any one has tried the patch from Peter Lebbing on VLAN tag on UBNT RouterStation platform and get it work properly. Regards, Chun Yeow ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/op