]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
vlan: Use is_vlan_dev()
authorJoonwoo Park <joonwpark81@gmail.com>
Tue, 8 Jul 2008 10:22:16 +0000 (03:22 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 8 Jul 2008 10:22:16 +0000 (03:22 -0700)
Use simplified is_vlan_dev function.

Signed-off-by: Joonwoo Park <joonwpark81@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/8021q/vlan.c
net/8021q/vlan_dev.c
net/8021q/vlanproc.c

index b529110c9355bcbff3c3b2c5a54d4e3c66b556cd..8141e2dc510be6e99833cfe3ac89fbeb2afac189 100644 (file)
@@ -570,8 +570,7 @@ static int vlan_ioctl_handler(struct net *net, void __user *arg)
                        goto out;
 
                err = -EINVAL;
-               if (args.cmd != ADD_VLAN_CMD &&
-                   !(dev->priv_flags & IFF_802_1Q_VLAN))
+               if (args.cmd != ADD_VLAN_CMD && !is_vlan_dev(dev))
                        goto out;
        }
 
index 4a8525927c276f8fbf10c86068d67d6f42d81ad4..88f318a9601d6fb23128cfce0494c338ea5679b2 100644 (file)
@@ -694,7 +694,7 @@ static int vlan_dev_init(struct net_device *dev)
                dev->hard_start_xmit = vlan_dev_hard_start_xmit;
        }
 
-       if (real_dev->priv_flags & IFF_802_1Q_VLAN)
+       if (is_vlan_dev(real_dev))
                subclass = 1;
 
        lockdep_set_class_and_subclass(&dev->_xmit_lock,
index 08b54b593d565df95a7b64629b793371df8c5d4d..6073a888b6f92610ce6a3c95b509e4293618976b 100644 (file)
@@ -290,7 +290,7 @@ static int vlandev_seq_show(struct seq_file *seq, void *offset)
        static const char fmt[] = "%30s %12lu\n";
        int i;
 
-       if (!(vlandev->priv_flags & IFF_802_1Q_VLAN))
+       if (!is_vlan_dev(vlandev))
                return 0;
 
        seq_printf(seq,