Skip to content

Commit

Permalink
ipv4: mask tos for input route
Browse files Browse the repository at this point in the history
Restore the lost masking of TOS in input route code to
allow ip rules to match it properly.

Problem [1] noticed by Shmulik Ladkani <[email protected]>

[1] http://marc.info/?t=137331755300040&r=1&w=2

Fixes: 89aef89 ("ipv4: Delete routing cache.")
Signed-off-by: Julian Anastasov <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
Julian Anastasov authored and davem330 committed Feb 26, 2017
1 parent 8bcfd09 commit 6e28099
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions net/ipv4/route.c
Original file line number Diff line number Diff line change
Expand Up @@ -2009,6 +2009,7 @@ int ip_route_input_noref(struct sk_buff *skb, __be32 daddr, __be32 saddr,
{
int res;

tos &= IPTOS_RT_MASK;
rcu_read_lock();

/* Multicast recognition logic is moved from route cache to here.
Expand Down

0 comments on commit 6e28099

Please sign in to comment.