aboutsummaryrefslogtreecommitdiffstats
path: root/net/tipc/node.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/tipc/node.c')
-rw-r--r--net/tipc/node.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/net/tipc/node.c b/net/tipc/node.c
index 937cc6192bcf..703875fd6cde 100644
--- a/net/tipc/node.c
+++ b/net/tipc/node.c
@@ -1079,7 +1079,7 @@ static bool tipc_node_check_state(struct tipc_node *n, struct sk_buff *skb,
1079 u16 exp_pkts = msg_msgcnt(hdr); 1079 u16 exp_pkts = msg_msgcnt(hdr);
1080 u16 rcv_nxt, syncpt, dlv_nxt; 1080 u16 rcv_nxt, syncpt, dlv_nxt;
1081 int state = n->state; 1081 int state = n->state;
1082 struct tipc_link *l, *pl = NULL; 1082 struct tipc_link *l, *tnl, *pl = NULL;
1083 struct tipc_media_addr *maddr; 1083 struct tipc_media_addr *maddr;
1084 int i, pb_id; 1084 int i, pb_id;
1085 1085
@@ -1164,12 +1164,20 @@ static bool tipc_node_check_state(struct tipc_node *n, struct sk_buff *skb,
1164 1164
1165 /* Open tunnel link when parallel link reaches synch point */ 1165 /* Open tunnel link when parallel link reaches synch point */
1166 if ((n->state == NODE_SYNCHING) && tipc_link_is_synching(l)) { 1166 if ((n->state == NODE_SYNCHING) && tipc_link_is_synching(l)) {
1167 if (tipc_link_is_synching(l)) {
1168 tnl = l;
1169 } else {
1170 tnl = pl;
1171 pl = l;
1172 }
1167 dlv_nxt = pl->rcv_nxt - mod(skb_queue_len(pl->inputq)); 1173 dlv_nxt = pl->rcv_nxt - mod(skb_queue_len(pl->inputq));
1168 if (more(dlv_nxt, n->sync_point)) { 1174 if (more(dlv_nxt, n->sync_point)) {
1169 tipc_link_fsm_evt(l, LINK_SYNCH_END_EVT); 1175 tipc_link_fsm_evt(tnl, LINK_SYNCH_END_EVT);
1170 tipc_node_fsm_evt(n, NODE_SYNCH_END_EVT); 1176 tipc_node_fsm_evt(n, NODE_SYNCH_END_EVT);
1171 return true; 1177 return true;
1172 } 1178 }
1179 if (l == pl)
1180 return true;
1173 if ((usr == TUNNEL_PROTOCOL) && (mtyp == SYNCH_MSG)) 1181 if ((usr == TUNNEL_PROTOCOL) && (mtyp == SYNCH_MSG))
1174 return true; 1182 return true;
1175 if (usr == LINK_PROTOCOL) 1183 if (usr == LINK_PROTOCOL)