linux/net/tipc
Tuong Lien 712042313b tipc: fix false detection of retransmit failures
This commit eliminates the use of the link 'stale_limit' & 'prev_from'
(besides the already removed - 'stale_cnt') variables in the detection
of repeated retransmit failures as there is no proper way to initialize
them to avoid a false detection, i.e. it is not really a retransmission
failure but due to a garbage values in the variables.

Instead, a jiffies variable will be added to individual skbs (like the
way we restrict the skb retransmissions) in order to mark the first skb
retransmit time. Later on, at the next retransmissions, the timestamp
will be checked to see if the skb in the link transmq is "too stale",
that is, the link tolerance time has passed, so that a link reset will
be ordered. Note, just checking on the first skb in the queue is fine
enough since it must be the oldest one.
A counter is also added to keep track the actual skb retransmissions'
number for later checking when the failure happens.

The downside of this approach is that the skb->cb[] buffer is about to
be exhausted, however it is always able to allocate another memory area
and keep a reference to it when needed.

Fixes: 77cf8edbc0 ("tipc: simplify stale link failure criteria")
Reported-by: Hoang Le <hoang.h.le@dektech.com.au>
Acked-by: Ying Xue <ying.xue@windriver.com>
Acked-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: Tuong Lien <tuong.t.lien@dektech.com.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-08-16 16:27:13 -07:00
..
Kconfig
Makefile
addr.c tipc: initialise addr_trail_end when setting node addresses 2019-08-11 21:40:04 -07:00
addr.h
bcast.c tipc: rename function msg_get_wrapped() to msg_inner_hdr() 2019-06-25 13:42:54 -07:00
bcast.h
bearer.c tipc: use rcu dereference functions properly 2019-07-07 13:18:53 -07:00
bearer.h
core.c
core.h
diag.c
discover.c
discover.h
eth_media.c
group.c
group.h
ib_media.c
link.c tipc: fix false detection of retransmit failures 2019-08-16 16:27:13 -07:00
link.h
monitor.c
monitor.h
msg.c
msg.h tipc: fix false detection of retransmit failures 2019-08-16 16:27:13 -07:00
name_distr.c tipc: ensure head->lock is initialised 2019-07-12 15:34:26 -07:00
name_distr.h
name_table.c
name_table.h
net.c
net.h
netlink.c
netlink.h
netlink_compat.c tipc: compat: allow tipc commands without arguments 2019-08-01 18:14:00 -04:00
node.c tipc: initialize 'validated' field of received packets 2019-07-17 15:24:38 -07:00
node.h
socket.c tipc: fix unitilized skb list crash 2019-07-30 14:39:36 -07:00
socket.h
subscr.c
subscr.h
sysctl.c proc/sysctl: add shared variables for range check 2019-07-18 17:08:07 -07:00
topsrv.c tipc: Fix a typo 2019-07-21 11:41:01 -07:00
topsrv.h
trace.c
trace.h
udp_media.c tipc: use rcu dereference functions properly 2019-07-07 13:18:53 -07:00
udp_media.h