diff options
author | Julian Anastasov <ja@ssi.bg> | 2011-07-22 22:00:41 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-07-23 23:05:31 -0400 |
commit | b0fe4a31849063fcac0bdc93716ca92615e93f57 (patch) | |
tree | 440cba41924eb7f32a3f1506715c6fc50663d98a /net/ipv4 | |
parent | f6226dec5081f55bf7820b74a9acb7b20a8930a5 (diff) |
ipv4: use RT_TOS after some rt_tos conversions
rt_tos was changed to iph->tos but it must be filtered by RT_TOS
Signed-off-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/ipmr.c | 2 | ||||
-rw-r--r-- | net/ipv4/route.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/net/ipv4/ipmr.c b/net/ipv4/ipmr.c index aae2bd8cd924..58e879157976 100644 --- a/net/ipv4/ipmr.c +++ b/net/ipv4/ipmr.c | |||
@@ -1796,7 +1796,7 @@ static struct mr_table *ipmr_rt_fib_lookup(struct net *net, struct sk_buff *skb) | |||
1796 | struct flowi4 fl4 = { | 1796 | struct flowi4 fl4 = { |
1797 | .daddr = iph->daddr, | 1797 | .daddr = iph->daddr, |
1798 | .saddr = iph->saddr, | 1798 | .saddr = iph->saddr, |
1799 | .flowi4_tos = iph->tos, | 1799 | .flowi4_tos = RT_TOS(iph->tos), |
1800 | .flowi4_oif = rt->rt_oif, | 1800 | .flowi4_oif = rt->rt_oif, |
1801 | .flowi4_iif = rt->rt_iif, | 1801 | .flowi4_iif = rt->rt_iif, |
1802 | .flowi4_mark = rt->rt_mark, | 1802 | .flowi4_mark = rt->rt_mark, |
diff --git a/net/ipv4/route.c b/net/ipv4/route.c index 33137307d52a..1730689f560e 100644 --- a/net/ipv4/route.c +++ b/net/ipv4/route.c | |||
@@ -1740,7 +1740,7 @@ void ip_rt_get_source(u8 *addr, struct sk_buff *skb, struct rtable *rt) | |||
1740 | memset(&fl4, 0, sizeof(fl4)); | 1740 | memset(&fl4, 0, sizeof(fl4)); |
1741 | fl4.daddr = iph->daddr; | 1741 | fl4.daddr = iph->daddr; |
1742 | fl4.saddr = iph->saddr; | 1742 | fl4.saddr = iph->saddr; |
1743 | fl4.flowi4_tos = iph->tos; | 1743 | fl4.flowi4_tos = RT_TOS(iph->tos); |
1744 | fl4.flowi4_oif = rt->dst.dev->ifindex; | 1744 | fl4.flowi4_oif = rt->dst.dev->ifindex; |
1745 | fl4.flowi4_iif = skb->dev->ifindex; | 1745 | fl4.flowi4_iif = skb->dev->ifindex; |
1746 | fl4.flowi4_mark = skb->mark; | 1746 | fl4.flowi4_mark = skb->mark; |