https://github.com/torvalds/linux
Revision bc9259a8bae9e814fc1f775a1b3effa13e6ad330 authored by Nicolas Dichtel on 27 September 2012, 04:11:00 UTC, committed by David S. Miller on 27 September 2012, 23:27:39 UTC
When jiffies wraps around (for example, 5 minutes after the boot, see
INITIAL_JIFFIES) and peer has just been created, now - peer->rate_last can be
< XRLIM_BURST_FACTOR * timeout, so token is not set to the maximum value, thus
some icmp packets can be unexpectedly dropped.

Fix this case by initializing last_rate to 60 seconds in the past.

Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 68b3f28
History
Tip revision: bc9259a8bae9e814fc1f775a1b3effa13e6ad330 authored by Nicolas Dichtel on 27 September 2012, 04:11:00 UTC
inetpeer: fix token initialization
Tip revision: bc9259a
File Mode Size
Makefile -rw-r--r-- 394 bytes
compat.c -rw-r--r-- 18.4 KB
compat_mq.c -rw-r--r-- 4.1 KB
ipc_sysctl.c -rw-r--r-- 6.0 KB
ipcns_notifier.c -rw-r--r-- 2.2 KB
mq_sysctl.c -rw-r--r-- 2.7 KB
mqueue.c -rw-r--r-- 35.2 KB
msg.c -rw-r--r-- 20.9 KB
msgutil.c -rw-r--r-- 2.7 KB
namespace.c -rw-r--r-- 4.3 KB
sem.c -rw-r--r-- 42.1 KB
shm.c -rw-r--r-- 29.7 KB
syscall.c -rw-r--r-- 2.3 KB
util.c -rw-r--r-- 22.8 KB
util.h -rw-r--r-- 5.3 KB

back to top