]> git.baikalelectronics.ru Git - kernel.git/commit
tipc: fix flow control accounting for implicit connect
authorParthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com>
Tue, 25 Sep 2018 16:21:58 +0000 (18:21 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 25 Sep 2018 17:47:37 +0000 (10:47 -0700)
commit03f27ce5bc15e2b71df49b1adf0b84ff7370f92a
treeedbb2cc31d9e57b760b5f39c947f3d01a5476c5c
parent8920b9a3bb11ac222795f1f436fe44b838f60e94
tipc: fix flow control accounting for implicit connect

In the case of implicit connect message with data > 1K, the flow
control accounting is incorrect. At this state, the socket does not
know the peer nodes capability and falls back to legacy flow control
by return 1, however the receiver of this message will perform the
new block accounting. This leads to a slack and eventually traffic
disturbance.

In this commit, we perform tipc_node_get_capabilities() at implicit
connect and perform accounting based on the peer's capability.

Signed-off-by: Parthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com>
Signed-off-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/socket.c