summaryrefslogtreecommitdiffstats
path: root/net/sched/sch_teql.c
diff options
context:
space:
mode:
authorLorenzo Bianconi <lorenzo.bianconi@redhat.com>2019-02-06 19:18:04 +0100
committerBen Hutchings <ben@decadent.org.uk>2019-12-19 15:58:11 +0000
commitd4df303d9f271ac3bb45bea6e913aff32f8f9239 (patch)
treed7e7b5fdb4356bed5effc814503f246f59ff38b3 /net/sched/sch_teql.c
parented5da1455def82331805e192c03e4eb909276257 (diff)
downloadlinux-stable-d4df303d9f271ac3bb45bea6e913aff32f8f9239.tar.gz
linux-stable-d4df303d9f271ac3bb45bea6e913aff32f8f9239.tar.bz2
linux-stable-d4df303d9f271ac3bb45bea6e913aff32f8f9239.zip
net: ipv4: use a dedicated counter for icmp_v4 redirect packets
commit c09551c6ff7fe16a79a42133bcecba5fc2fc3291 upstream. According to the algorithm described in the comment block at the beginning of ip_rt_send_redirect, the host should try to send 'ip_rt_redirect_number' ICMP redirect packets with an exponential backoff and then stop sending them at all assuming that the destination ignores redirects. If the device has previously sent some ICMP error packets that are rate-limited (e.g TTL expired) and continues to receive traffic, the redirect packets will never be transmitted. This happens since peer->rate_tokens will be typically greater than 'ip_rt_redirect_number' and so it will never be reset even if the redirect silence timeout (ip_rt_redirect_silence) has elapsed without receiving any packet requiring redirects. Fix it by using a dedicated counter for the number of ICMP redirect packets that has been sent by the host I have not been able to identify a given commit that introduced the issue since ip_rt_send_redirect implements the same rate-limiting algorithm from commit 1da177e4c3f4 ("Linux-2.6.12-rc2") Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> [bwh: Backported to 3.16: adjust context, indentation] Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'net/sched/sch_teql.c')
0 files changed, 0 insertions, 0 deletions