]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
Fix VLAN address syncing.
authorPatrick McHardy <kaber@trash.net>
Tue, 13 Nov 2007 08:11:51 +0000 (00:11 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 16 Nov 2007 16:27:37 +0000 (08:27 -0800)
patch d932e04a5e7b146c5f9bf517714b986a432a7594 in mainline.

[PATCH] [VLAN]: Don't synchronize addresses while the vlan device is down

While the VLAN device is down, the unicast addresses are not configured
on the underlying device, so we shouldn't attempt to sync them.

Noticed by Dmitry Butskoy <buc@odusz.so-cdu.ru>

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/8021q/vlan.c

index 2a546919d6fbd72e10ea6c01dc908e84eb012aa4..327ff81ebbd7c230d84d6c2266cad9bc0ae5579c 100644 (file)
@@ -629,6 +629,10 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event,
                        if (!vlandev)
                                continue;
 
+                       flgs = vlandev->flags;
+                       if (!(flgs & IFF_UP))
+                               continue;
+
                        vlan_sync_address(dev, vlandev);
                }
                break;