lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Sun, 22 May 2011 12:39:18 -0700 From: ebiederm@...ssion.com (Eric W. Biederman) To: David Miller <davem@...emloft.net> Cc: Jiri Pirko <jpirko@...hat.com>, Nicolas de Pesloüan <nicolas.2p.debian@...il.com>, Changli Gao <xiaosuo@...il.com>, netdev@...r.kernel.org, shemminger@...ux-foundation.org, kaber@...sh.net, fubar@...ibm.com, eric.dumazet@...il.com, andy@...yhouse.net, Jesse Gross <jesse@...ira.com> Subject: [PATCH 1/3] vlan: Do not support clearing VLAN_FLAG_REORDER_HDR Simplify the vlan handling code by not supporing clearing of VLAN_FLAG_REORDER_HDR. Which means we always make the vlan handling code strip the vlan header from the packets, and always insert the vlan header when transmitting packets. Not stripping the vlan header has alwasy been broken in combination with vlan hardware accelleration. Now that we are making everything look like accelerated vlan handling not stripping the vlan header is always broken. I don't think anyone actually cares so simply stop supporting the broken case. Signed-off-by: Eric W. Biederman <ebiederm@...ssion.com> --- net/8021q/vlan_dev.c | 3 +-- net/8021q/vlan_netlink.c | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c index f247f5b..20629fe 100644 --- a/net/8021q/vlan_dev.c +++ b/net/8021q/vlan_dev.c @@ -242,8 +242,7 @@ int vlan_dev_change_flags(const struct net_device *dev, u32 flags, u32 mask) struct vlan_dev_info *vlan = vlan_dev_info(dev); u32 old_flags = vlan->flags; - if (mask & ~(VLAN_FLAG_REORDER_HDR | VLAN_FLAG_GVRP | - VLAN_FLAG_LOOSE_BINDING)) + if (mask & ~(VLAN_FLAG_GVRP | VLAN_FLAG_LOOSE_BINDING)) return -EINVAL; vlan->flags = (old_flags & ~mask) | (flags & mask); diff --git a/net/8021q/vlan_netlink.c b/net/8021q/vlan_netlink.c index be9a5c1..a638a4c 100644 --- a/net/8021q/vlan_netlink.c +++ b/net/8021q/vlan_netlink.c @@ -59,9 +59,7 @@ static int vlan_validate(struct nlattr *tb[], struct nlattr *data[]) } if (data[IFLA_VLAN_FLAGS]) { flags = nla_data(data[IFLA_VLAN_FLAGS]); - if ((flags->flags & flags->mask) & - ~(VLAN_FLAG_REORDER_HDR | VLAN_FLAG_GVRP | - VLAN_FLAG_LOOSE_BINDING)) + if (flags->mask & ~(VLAN_FLAG_GVRP | VLAN_FLAG_LOOSE_BINDING)) return -EINVAL; } -- 1.7.5.1.217.g4e3aa -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists