summaryrefslogtreecommitdiff
path: root/net/ipv4/ip_gre.c
diff options
context:
space:
mode:
authorAndreas Jaggi <aj@open.ch>2009-07-14 20:35:59 +0400
committerDavid S. Miller <davem@davemloft.net>2009-07-14 20:35:59 +0400
commitee686ca919193d7c1f87f907e732df5e2f942523 (patch)
tree2a1f528de455ffc952ab9bc795dd38a863604aaa /net/ipv4/ip_gre.c
parentc8159b2db1b49f6bda4429008c85108e2da60712 (diff)
downloadlinux-ee686ca919193d7c1f87f907e732df5e2f942523.tar.xz
gre: fix ToS/DiffServ inherit bug
Fixes two bugs: - ToS/DiffServ inheritance was unintentionally activated when using impair fixed ToS values - ECN bit was lost during ToS/DiffServ inheritance Signed-off-by: Andreas Jaggi <aj@open.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ip_gre.c')
-rw-r--r--net/ipv4/ip_gre.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c
index 44e2a3d2359a..cb4a0f4bd5e5 100644
--- a/net/ipv4/ip_gre.c
+++ b/net/ipv4/ip_gre.c
@@ -735,10 +735,10 @@ static int ipgre_tunnel_xmit(struct sk_buff *skb, struct net_device *dev)
}
tos = tiph->tos;
- if (tos&1) {
+ if (tos == 1) {
+ tos = 0;
if (skb->protocol == htons(ETH_P_IP))
tos = old_iph->tos;
- tos &= ~1;
}
{