summaryrefslogtreecommitdiffstats
path: root/net/tipc/core.h
diff options
context:
space:
mode:
authorJon Paul Maloy <jon.maloy@ericsson.com>2015-11-19 14:30:41 -0500
committerDavid S. Miller <davem@davemloft.net>2015-11-20 14:06:10 -0500
commit5c10e9794013143eec80d494603d46dcb219970a (patch)
tree6e64db50e9d13388c872e47e1b3306d52c8298f9 /net/tipc/core.h
parentc7cad0d6f70cd4ce8644ffe528a4df1cdc2e77f5 (diff)
downloadlinux-stable-5c10e9794013143eec80d494603d46dcb219970a.tar.gz
linux-stable-5c10e9794013143eec80d494603d46dcb219970a.tar.bz2
linux-stable-5c10e9794013143eec80d494603d46dcb219970a.zip
tipc: small cleanup of function tipc_node_check_state()
The function tipc_node_check_state() contains the core logics for handling link synchronization and failover. For this reason, it is important to keep it as comprehensible as possible. In this commit, we make three small cleanups. 1) If the node is in state SELF_DOWN_PEER_LEAVING and the received packet confirms that the peer has lost contact, there will be no further action in this function. To make this clearer, we return from the function directly after the state change. 2) Since commit 0f8b8e28fb3241f9fd ("tipc: eliminate risk of stalled link synchronization") only the logically first TUNNEL_PROTO/SYNCH packet can alter the link state and set the synch point, independently of arrival order. Hence, there is not any longer any need to adjust the synch value in case such packets arrive in disorder. We remove this adjustment. 3) It is the intention that any message arriving on any of the links may trig a check for and possible termination of a node SYNCH state. A redundant and unnoticed check for tipc_link_is_synching() obviously beats this purpose, with the effect that only packets arriving on the synching link may currently end the synch state. We remove this check. This change will further shorten the synchronization period between parallel links. Reviewed-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/tipc/core.h')
0 files changed, 0 insertions, 0 deletions