Re: vlan Q in Q - [WAS Re: Using a switch fabric to emulate multiple NICs]

Ben Greear <[email protected]>
Newsgroups gmane.linux.drivers.vlan
Organization Candela Technologies
Message-ID <[email protected]>
Cam wrote:
> Alex
> 
>> Ben Greear <[email protected]> wrote:
> 
> [...]
> 
>>> You may also have to hack on the VLAN code a bit...I'm not sure it 
>>> completely supports
>>> vlans in vlans, though it should be fairly straight-forward to add 
>>> such support.
> 
> 
> [...]
> 
>> But I cannot see why this should be a problem.  As I see it 8021q.o 
>> just adds a vlan tag to packets
>> going down and strips the outer tag on packets going up.  Please can 
>> you expand on this.
> 
> 
> FWIW I tried this recently and found that packets only had the outermost 
> tag, there wasn't the nesting behaviour I expected. I would be 
> interested enough to try a patch, if one exists.

If a packet with VID of 6 is to be transmitted on a vlan device with
VID 7, we change the VID to match the vlan device.  This makes bridging
work, I believe.

You would need to add a flag to tell the base VLAN device to always
encapsulate.


My suggestion is to copy the VLAN code and make a stripped down version
that does exactly what you need to fake out your switch device and
nothing else.  Go ahead and present the interfaces as true ethernet
interfaces, and have your driver add/strip tags accordingly.

I think trying to re-use the standard vlan module for this will be nothing
but trouble.

Ben

> 
> -Cam
> 


-- 
Ben Greear <[email protected]>
Candela Technologies Inc  http://www.candelatech.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.