diff options
author | Vlad Yasevich <vyasevich@gmail.com> | 2014-09-15 15:24:26 -0400 |
---|---|---|
committer | Jiri Slaby <jslaby@suse.cz> | 2014-10-17 09:43:14 +0200 |
commit | 77bd83323c2423d2f42bacc2140923860e269af9 (patch) | |
tree | e095ac12b8f9f6667490cfcf7913636f9f278f98 /net | |
parent | 6266beeee8158338a894b2ab3a477424e9631696 (diff) | |
download | lwn-77bd83323c2423d2f42bacc2140923860e269af9.tar.gz lwn-77bd83323c2423d2f42bacc2140923860e269af9.zip |
bridge: Fix br_should_learn to check vlan_enabled
[ Upstream commit c095f248e63ada504dd90c90baae673ae10ee3fe ]
As Toshiaki Makita pointed out, the BRIDGE_INPUT_SKB_CB will
not be initialized in br_should_learn() as that function
is called only from br_handle_local_finish(). That is
an input handler for link-local ethernet traffic so it perfectly
correct to check br->vlan_enabled here.
Reported-by: Toshiaki Makita<toshiaki.makita1@gmail.com>
Fixes: 20adfa1 bridge: Check if vlan filtering is enabled only once.
Signed-off-by: Vladislav Yasevich <vyasevic@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Diffstat (limited to 'net')
-rw-r--r-- | net/bridge/br_vlan.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bridge/br_vlan.c b/net/bridge/br_vlan.c index 7f6cec3773bc..f0db99f57deb 100644 --- a/net/bridge/br_vlan.c +++ b/net/bridge/br_vlan.c @@ -273,7 +273,7 @@ bool br_should_learn(struct net_bridge_port *p, struct sk_buff *skb, u16 *vid) struct net_port_vlans *v; /* If filtering was disabled at input, let it pass. */ - if (!BR_INPUT_SKB_CB(skb)->vlan_filtered) + if (!br->vlan_enabled) return true; v = rcu_dereference(p->vlan_info); |