[LiSA-Devel] MSTP inplementation in Lisa

Radu Rendec radu.rendec at mindbit.ro
Fri Jul 23 11:02:20 EEST 2010


On Wed, 2010-07-21 at 20:22 +0800, 李家宏 wrote:
> Moreover i've wondering if we can determine every bridge port's state,
> either in disabling, learning, or forwarding by first examining the
> packet's vlan tag before relay the packet. Note that the packet is
> common upper layer packet. I think this mechanism is essential in
> inplementing MSTP in Lisa.

Hello,

Per-vlan port state should be stored inside struct net_switch_port,
similar to the forbidden_vlans bitmap. Then it can be checked early in
the switching code, most probably in sw_handle_frame(), before accepting
the frame and entering the forwarding code (fdb_learn() and
sw_forward()).

It's debatable if it's better to completely replace the forbidden_vlans
bitmap with a vlan_id-indexed array of per-vlan port bits that include
both MSTP port state and whether the port is configured in that vlan or
not.

Best regards,

Radu




More information about the LiSA-Devel mailing list