From: Joonwoo Park Date: Tue, 8 Jul 2008 10:22:16 +0000 (-0700) Subject: vlan: Use is_vlan_dev() X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=26a25239d7a660cc7162e2463b48b40d544364d0;p=linux-beck.git vlan: Use is_vlan_dev() Use simplified is_vlan_dev function. Signed-off-by: Joonwoo Park Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller --- diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c index b529110c9355..8141e2dc510b 100644 --- a/net/8021q/vlan.c +++ b/net/8021q/vlan.c @@ -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; } diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c index 4a8525927c27..88f318a9601d 100644 --- a/net/8021q/vlan_dev.c +++ b/net/8021q/vlan_dev.c @@ -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, diff --git a/net/8021q/vlanproc.c b/net/8021q/vlanproc.c index 08b54b593d56..6073a888b6f9 100644 --- a/net/8021q/vlanproc.c +++ b/net/8021q/vlanproc.c @@ -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,