802.1q vlan range on E3000 - VIDs beyond 15 possible?

Post new topic   This topic is locked: you cannot edit posts or make replies.    DD-WRT Forum Index -> Broadcom SoC based Hardware
Goto page Previous  1, 2, 3 ... 5, 6, 7 ... 9, 10, 11  Next
Author Message
zhaolinger
DD-WRT Novice


Joined: 15 Apr 2011
Posts: 8

PostPosted: Sat Apr 16, 2011 20:07    Post subject: Reply with quote
phuzi0n wrote:
You're not changing any nvram variables by echoing to /proc/switch, only the running configuration of the switch is changed.

I don't know if you can leave the CPU interface (5 or Cool out of the VLAN or not so just try it and find out. If you have to use it then it's okay, you can just not assign any IP address to the VLAN interface to prevent anything from being routed to it.


Thanks for your clarification, now i know using this method does not reflects on the nvram variables, so i cannot check the status this way like before.

But for my 2nd question, my scenario is that i want to set my wan as a truck, that would route all tag "10" traffic as internet traffic to port 1~3 as per normal. But for tag "20" and "30" traffic that also pass through the wan port, they shall not be route to port 1~3 (standard lan that connect to 3 pc), instead they shall directly pass in/out as same tagged traffic to port 4 just like a standard switch. Port 4 shall not assign any ip to device connected to it, just act like a bridge in this case (if i not wrong, a managed switch does not have dhcp to assign ips to device connected to it).

Since i could not find any info/posts by someone else with similar scenario, i do not know how to go about to configure my vlan setting to behave this way.

Thanks in advance for any helps you can provide in this case.
Sponsor
redge76
DD-WRT Novice


Joined: 23 Apr 2011
Posts: 3

PostPosted: Sat Apr 23, 2011 1:50    Post subject: Reply with quote
Hi,

I need VLAN ID above 2000.
I tried the module of tangsoft and it works (but only for ID<128)

So:
* tangsoft do you have a module with more VLAN enabled ?
* Is there a firmware with this patch included ?
* Is my only solution to build the module myself? If yes I should start with the "Development" page in the wiki, download cross compiler, download source (18gb!) patch the file. and build? Right?

Thanks,
Redge
tangsoft
DD-WRT User


Joined: 18 Sep 2010
Posts: 60

PostPosted: Mon Apr 25, 2011 15:51    Post subject: Reply with quote
for question 1:it needs to recompile the module. I will give a try if the compile environment in my VM is still working.And again, like gert said, it is on your own risk to try the unauthorized module patch.
Bye the way, I am not frequently log in the forum recently.
question 2: may any Guru here answer it?
question 3: you only need to compile the module, not the entire kernel.

redge76 wrote:
Hi,

I need VLAN ID above 2000.
I tried the module of tangsoft and it works (but only for ID<128)

So:
* tangsoft do you have a module with more VLAN enabled ?
* Is there a firmware with this patch included ?
* Is my only solution to build the module myself? If yes I should start with the "Development" page in the wiki, download cross compiler, download source (18gb!) patch the file. and build? Right?

Thanks,
Redge
checho
DD-WRT Guru


Joined: 27 Feb 2007
Posts: 527
Location: Bulgaria

PostPosted: Tue Aug 02, 2011 23:58    Post subject: Reply with quote
Hello,

Over a day trying to fix this on WRT54GL. I compiled a switch-robo.o module for 15508 / 2.4.37 with 128 vlans populated.

The following issues are faced:
1. vconfig actually does nothing. vconfig add vlan1 99 for example created vlan99 but no traffic passes through it. As if I have not changed the module.

2. Web interface Setup - Networking. There I do tagging on vlan1 and put a tag 99 with default priority 0. Interface vlan1.99 is created and then I can only pass traffic from the device to world. Received traffic is not caught as vlan99, frames are just dropped.

Code:
root@DD-WRT:~# cat /proc/switch/eth0/vlan/99/ports
4t      5t     
root@DD-WRT:~# cat /proc/switch/eth0/vlan/1/ports 
4       5t* 


Any ideas?
checho
DD-WRT Guru


Joined: 27 Feb 2007
Posts: 527
Location: Bulgaria

PostPosted: Mon Aug 08, 2011 15:59    Post subject: Reply with quote
checho wrote:
Hello,

Over a day trying to fix this on WRT54GL. I compiled a switch-robo.o module for 15508 / 2.4.37 with 128 vlans populated.

The following issues are faced:
1. vconfig actually does nothing. vconfig add vlan1 99 for example created vlan99 but no traffic passes through it. As if I have not changed the module.

2. Web interface Setup - Networking. There I do tagging on vlan1 and put a tag 99 with default priority 0. Interface vlan1.99 is created and then I can only pass traffic from the device to world. Received traffic is not caught as vlan99, frames are just dropped.

Code:
root@DD-WRT:~# cat /proc/switch/eth0/vlan/99/ports
4t      5t     
root@DD-WRT:~# cat /proc/switch/eth0/vlan/1/ports 
4       5t* 


Any ideas?


I figured out a mistake I am doing and it was that I should be configuring vlans to eth0 hardware interface. So I am doing for example

vconfig add eth0 10 and it is creating vlan 10 as a tag.

I need to have it configured so that WAN port passes untagged traffic from the IP network that is configured on vlan1 which is the default wan port. Also there should be vlan tagged traffic going out through WAN with a tag of 10. I manage to get it done with VID <15.

Code:
root@DD-WRT:~# cat /proc/switch/eth0/vlan/10/ports
4t      5t     


Since my vid is <15 it does work fine. But I am trying to configure another populated vlans in /proc/switch/eth0/vlan/* and it does not seem to work for vid>15. If I define config for vid>15 it takes priority over all other configures and untagged traffic stops going through the wan port.

Also if I do for example three tagged vlans and if I submit '4t 5t' for all of them in /proc/switch/eth0/vlan/ they do not go out all but only goes the last one configured.

Also interesting fact is that I tried populating vlans up to 2000 and they created only up to 1650. And listing /proc/switch/eth0/vlan results in rebooting of device.

Maybe best patch would be if I could update switch-robo in such a way that it creates only vlans listed in nvram variable in order.

For example we have:
nvram get vlan_numbers
containing 100 200 300 400 1100 1200 1300 1400

and we patch switch-robo.c so that it reads that variable and populates only these vlan numbers in addition to default 1-15. But too bad I don't have sufficient 'c' proficiency to accomplish that.

Linksys WRT54GL / Netgear WGR614L


Last edited by checho on Wed Aug 10, 2011 17:57; edited 1 time in total
checho
DD-WRT Guru


Joined: 27 Feb 2007
Posts: 527
Location: Bulgaria

PostPosted: Wed Aug 10, 2011 10:49    Post subject: Reply with quote
Please help me do this ... is the only way to compile kernel with patches?
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 10141

PostPosted: Wed Aug 10, 2011 20:36    Post subject: Reply with quote
This patch is basically only for new switches that can handle 4k VLAN's. You should get a model with a BCM53115 switch to use the patch. Old models only support 16 VLAN's total but can still tag any of the 4k possible VID's for each of those 16 VLAN's, so they will need a more complicated patch to be able to support higher VID's properly while restricting the total VLAN count to 16.
_________________
Read the forum announcements thoroughly! Be cautious if you're inexperienced.
Available for paid consulting. (Don't PM about complicated setups otherwise)
Looking for bricks and spare routers to expand my collection. (not interested in G spec models)
checho
DD-WRT Guru


Joined: 27 Feb 2007
Posts: 527
Location: Bulgaria

PostPosted: Thu Aug 11, 2011 7:23    Post subject: Reply with quote
phuzi0n wrote:
This patch is basically only for new switches that can handle 4k VLAN's. You should get a model with a BCM53115 switch to use the patch. Old models only support 16 VLAN's total but can still tag any of the 4k possible VID's for each of those 16 VLAN's, so they will need a more complicated patch to be able to support higher VID's properly while restricting the total VLAN count to 16.


OK that's fine but can I rely only on patching switch-robo.o kernel module or I have to compile whole kernel...
AdNauseam
DD-WRT Novice


Joined: 02 Sep 2011
Posts: 1

PostPosted: Fri Sep 02, 2011 16:00    Post subject: Reply with quote
Does anyone know why I am not seeing the vlanX interface get created after doing "vconfig add"?

- Cisco E3000
- Tried first with dd-wrt.v24-14929_NEWD-2_K2.6_big-e2k-e3k and now with dd-wrt.v24-17084_NEWD-2_K2.6_big-nv60k.bin
- Using the switch-robo.ko module from cron2 (http://www.dd-wrt.com/phpBB2/viewtopic.php?p=534980#534980)

Code:

root@wifi1:/jffs# lsmod
Module                  Size  Used by
etherip                 8192  0
jffs2                  77824  1
switch_robo             4096  0
switch_core             8192  1 switch_robo
bcm57xx               102400  0

root@wifi1:/jffs# rmmod switch-robo
root@wifi1:/jffs# lsmod
Module                  Size  Used by
etherip                 8192  0
jffs2                  77824  1
switch_core             8192  0
bcm57xx               102400  0

root@wifi1:/jffs# insmod switch-robo-cron2.ko
root@wifi1:/jffs# lsmod
Module                  Size  Used by
switch_robo             8192  0
etherip                 8192  0
jffs2                  77824  1
switch_core             8192  1 switch_robo
bcm57xx               102400  0

root@wifi1:/jffs# echo "1t 8" > /proc/switch/eth0/vlan/102/ports
root@wifi1:/jffs# echo "1t 8" > /proc/switch/eth0/vlan/1000/ports
root@wifi1:/jffs# echo "1 8*" > /proc/switch/eth0/vlan/999/ports

root@wifi1:/jffs# vconfig add eth0 102
root@wifi1:/jffs# ifconfig vlan102
root@wifi1:/jffs#

root@wifi1:/jffs# ifconfig vlan102 up
root@wifi1:/jffs# ifconfig vlan102         
root@wifi1:/jffs#

root@wifi1:/jffs# ifconfig -a | grep Link
br0       Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:32
br0:0     Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:32
eth0      Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:32
eth0.102  Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:32
eth1      Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:34
eth2      Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:35
etherip0  Link encap:Ethernet  HWaddr 1A:F4:A4:A3:E6:F8
gre0      Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
lo        Link encap:Local Loopback
teql0     Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
tunl0     Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
vlan1     Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:32 
vlan2     Link encap:Ethernet  HWaddr 98:FC:11:8B:A1:33
orca_nbk
DD-WRT Novice


Joined: 21 Aug 2011
Posts: 3

PostPosted: Tue Sep 13, 2011 18:30    Post subject: Reply with quote
Hi!
WRT54GL module and instructions can be found here.
LOM
DD-WRT Guru


Joined: 28 Dec 2008
Posts: 7647

PostPosted: Tue Sep 13, 2011 18:37    Post subject: Reply with quote
orca_nbk wrote:
Hi!
WRT54GL module and instructions can be found here.


Interesting..
How did you get the 1670 vlan pid limit?
It is a strange number that doesn't correspond to the number of bits in the switch register for holding the pids and is not an even binary number Confused

_________________
Kernel panic: Aiee, killing interrupt handler!
orca_nbk
DD-WRT Novice


Joined: 21 Aug 2011
Posts: 3

PostPosted: Wed Sep 14, 2011 5:37    Post subject: Reply with quote
checho wrote:


Also interesting fact is that I tried populating vlans up to 2000 and they created only up to 1650.


In my case it was VID 1670. So this module was patched to max VID 1670
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 10141

PostPosted: Sun Sep 18, 2011 21:14    Post subject: Reply with quote
orca_nbk wrote:
Hi!
WRT54GL module and instructions can be found here.

The groups of 16 is a very interesting find. I had experimented with patched switch-robo's on BCM5325 switches before and had gotten it to semi-work but kept having the switch lock up when I tried creating several VLAN's spread apart.

Reviewing the source code for the switch driver (bcmrobo.c) it seems that there are indeed 4 bits (2^4=16) that get right shifted off (vid >> 4) for BCM5325 switch with corerev<3 which leaves the REG_VLAN_WRITE register holding a multiple of 16 instead of the actual vid.

Code:
vlan_setup:
      /* setup VLAN ID and VLAN memberships */

      val32 = (untag |         /* untag enable */
               member);         /* vlan members */
      if (robo->devid == DEVID5325) {
         if (robo->corerev < 3) {
            val32 |= ((1 << 20) |      /* valid write */
                      ((vid >> 4) << 12));   /* vlan id bit[11:4] */
         } else {
            val32 |= ((1 << 24) |      /* valid write */
                      (vid << 12));   /* vlan id bit[11:4] */
         }
         ET_MSG(("bcm_robo_config_vlan: programming REG_VLAN_WRITE %08x\n", val32));

         /* VLAN Write Register (Page 0x34, Address 0x08-0x0B) */
         robo->ops->write_reg(robo, PAGE_VLAN, REG_VLAN_WRITE, &val32,
                              sizeof(val32));
         /* VLAN Table Access Register (Page 0x34, Address 0x06-0x07) */
         val16 = ((1 << 13) |   /* start command */
                  (1 << 12) |   /* write state */
                  vid);      /* vlan id */
         robo->ops->write_reg(robo, PAGE_VLAN, REG_VLAN_ACCESS, &val16,
                              sizeof(val16));
      } else {

The REG_VLAN_ACCESS register still gets the full VID though so maybe it's just a bug in switch-robo not setting the REG_VLAN_WRITE register properly each time? I don't have much time right now to look into it further.

_________________
Read the forum announcements thoroughly! Be cautious if you're inexperienced.
Available for paid consulting. (Don't PM about complicated setups otherwise)
Looking for bricks and spare routers to expand my collection. (not interested in G spec models)
yimzhu
DD-WRT Novice


Joined: 05 Oct 2011
Posts: 1

PostPosted: Thu Oct 06, 2011 2:30    Post subject: erverthing is ok but multicast doesn't work Reply with quote
I followed my wrt610n v2 as tangsoft did, now everything is ok except multicast doesn't work, I've disabled SPI in ddwrt. Does anyone know how to enable multicast in ddwrt?

To tangsoft: could you post your script? Thanks a lot.
francx
DD-WRT Novice


Joined: 11 Dec 2011
Posts: 3

PostPosted: Sun Dec 18, 2011 7:52    Post subject: Reply with quote
Hi!

My ISP have over one cable Internet (VLAN 0) and IPTV (VLAN 3999). My Linksys WRT54GL listen on WAN port only VLAN 1. I want set it to listen VLAN 3999 to.

Is that possible?

Please help!
Goto page Previous  1, 2, 3 ... 5, 6, 7 ... 9, 10, 11  Next Display posts from previous:    Page 6 of 11
Post new topic   This topic is locked: you cannot edit posts or make replies.    DD-WRT Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum