[PATCH net v1 1/1] tipc: fix hanging poll() for stream sockets

2017-12-28 Thread Parthasarathy Bhuvaragan
ations are not woken when the connection is ESTABLISHED and hence sleep forever. In this commit, we fix it by including the POLLOUT event for sockets in TIPC_CONNECTING state. Fixes: 42b531de17d2f6 ("tipc: Fix missing connection request handling") Acked-by: Jon Maloy Signed-off-by: Part

[PATCH net v1 1/1] tipc: use only positive error codes in messages

2017-09-29 Thread Parthasarathy Bhuvaragan
bit error field of the message header as 0xf instead of TIPC_ERR_NO_NAME (1). The value 0xf is an unknown error code. In this commit, we set only positive error code. Fixes: e3a77561e7d32 ("tipc: split up function tipc_msg_eval()") Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/

[PATCH net v1 1/1] tipc: permit bond slave as bearer

2017-08-28 Thread Parthasarathy Bhuvaragan
protocol callback per device and look for tipc bearer from both the devices. Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/bearer.c | 26 +++--- net/tipc/bearer.h | 2 ++ 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/net/tipc/bearer.c b/net/tipc

[PATCH net v1 3/3] tipc: context imbalance at node read unlock

2017-08-24 Thread Parthasarathy Bhuvaragan
If we fail to find a valid bearer in tipc_node_get_linkname(), node_read_unlock() is called without holding the node read lock. This commit fixes this error. Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/node.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/tipc

[PATCH net v1 2/3] tipc: reassign pointers after skb reallocation / linearization

2017-08-24 Thread Parthasarathy Bhuvaragan
commit, we fix this error by ensuring that the pointers are re-assigned after any of these skb operations. Fixes: 29042e19f2c60 ("tipc: let function tipc_msg_reverse() expand header when needed") Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/msg.c | 7 +

[PATCH net v1 1/3] tipc: perform skb_linearize() before parsing the inner header

2017-08-24 Thread Parthasarathy Bhuvaragan
disturbances if the skb was non linear. In this commit, we perform linearization for the above messages. Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/node.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/net/tipc/node.c b/net/tipc/node.c index 9b4dcb6a16b5

[PATCH net v1 0/3] tipc: buffer reassignment fixes

2017-08-24 Thread Parthasarathy Bhuvaragan
This series contains fixes for buffer reassignments and a context imbalance. Parthasarathy Bhuvaragan (3): tipc: perform skb_linearize() before parsing the inner header tipc: reassign pointers after skb reallocation / linearization tipc: context imbalance at node read unlock net/tipc

[PATCH net v1 2/2] tipc: fix a race condition of releasing subscriber object

2017-08-22 Thread Parthasarathy Bhuvaragan
nic happened. By contrast, if we increase subscriber's refcnt before tipc_subscrb_subscrp_delete() is called in tipc_subscrp_cancel(), the panic issue can be avoided. Fixes: d094c4d5f5c7 ("tipc: add subscription refcount to avoid invalid delete") Reported-by: Parthasarathy Bhuvaraga

[PATCH net v1 1/2] tipc: remove subscription references only for pending timers

2017-08-22 Thread Parthasarathy Bhuvaragan
80 [tipc] RSP: 88003ba03e90 [39.604] ---[ end trace 79ce94b7216cb459 ]--- Fixes: 139bb36f754a ("tipc: advance the time of deleting subscription from subscriber->subscrp_list") Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 19 +++ 1 file changed, 7 i

[PATCH net v1 0/2] tipc: topology server fixes

2017-08-22 Thread Parthasarathy Bhuvaragan
The following commits fixes two race conditions causing general protection faults. Parthasarathy Bhuvaragan (1): tipc: remove subscription references only for pending timers Ying Xue (1): tipc: fix a race condition of releasing subscriber object net/tipc/subscr.c | 21

[PATCH net v1 0/3] tipc: fix hanging socket connections

2017-04-26 Thread Parthasarathy Bhuvaragan
This patch series contains fixes for the socket layer to prevent hanging / stale connections. Parthasarathy Bhuvaragan (3): tipc: Fix missing connection request handling tipc: improve error validations for sockets in CONNECTING state tipc: close the connection if protocol messages contain

[PATCH net v1 2/3] tipc: improve error validations for sockets in CONNECTING state

2017-04-26 Thread Parthasarathy Bhuvaragan
our users about them using sk_state_change(). Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/socket.c | 25 ++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 3b8df510a80c..38c367f6c

[PATCH net v1 1/3] tipc: Fix missing connection request handling

2017-04-26 Thread Parthasarathy Bhuvaragan
callback sk_data_ready(). Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/socket.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 566906795c8c..3b8df510a80c 100644 --- a/net/tipc/socket.c +++ b/net

[PATCH net v1 3/3] tipc: close the connection if protocol messages contain errors

2017-04-26 Thread Parthasarathy Bhuvaragan
-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/socket.c | 8 1 file changed, 8 insertions(+) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 38c367f6ced4..bdce99f9407a 100644 --- a/net/tipc/socket.c +++ b/net/tipc/socket.c @@ -866,6 +866,14 @@ static void

[PATCH net v1 2/2] tipc: fix socket flow control accounting error at tipc_recv_stream

2017-04-24 Thread Parthasarathy Bhuvaragan
skb. This leads to a flow control accounting error causing permanent congestion. In this commit, we fix this accounting error by always using the size of the incoming message. Fixes: 10724cc7bb78 ("tipc: redesign connection-level flow control") Signed-off-by: Parthasarathy Bhuvaragan R

[PATCH net v1 1/2] tipc: fix socket flow control accounting error at tipc_send_stream

2017-04-24 Thread Parthasarathy Bhuvaragan
n the partially sent bytes as the return value at link congestion. Fixes: 10724cc7bb78 ("tipc: redesign connection-level flow control") Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/

[PATCH net-next v1 1/2] tipc: add support for stream/seqpacket socketpairs

2017-03-29 Thread Parthasarathy Bhuvaragan
From: Erik Hugne sockets A and B are connected back-to-back, similar to what AF_UNIX does. Signed-off-by: Erik Hugne Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc

[PATCH net-next v1 0/2] tipc: add socketpair support

2017-03-29 Thread Parthasarathy Bhuvaragan
We add socketpair support for connection oriented sockets in the first patch and for connection less in the second. Erik Hugne (2): tipc: add support for stream/seqpacket socketpairs tipc: allow rdm/dgram socketpairs net/tipc/socket.c | 28 +--- 1 file changed, 25 ins

[PATCH net-next v1 2/2] tipc: allow rdm/dgram socketpairs

2017-03-29 Thread Parthasarathy Bhuvaragan
From: Erik Hugne for socketpairs using connectionless transport, we cache the respective node local TIPC portid to use in subsequent calls to send() in the socket's private data. Signed-off-by: Erik Hugne Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c

[PATCH net-next v1 2/2] tipc: adjust the policy of holding subscription kref

2017-03-28 Thread Parthasarathy Bhuvaragan
From: Ying Xue When a new subscription object is inserted into name_seq->subscriptions list, it's under name_seq->lock protection; when a subscription is deleted from the list, it's also under the same lock protection; similarly, when accessing a subscription by going through subscriptions list,

[PATCH net-next v1 1/2] tipc: advance the time of deleting subscription from subscriber->subscrp_list

2017-03-28 Thread Parthasarathy Bhuvaragan
Maloy Signed-off-by: Ying Xue Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c index 271cd66e4b3b..0649bc29c6bb 100644 --- a/net/tipc/subscr.c +++ b/net/tipc/subscr.c @@

[PATCH net-next v1 0/2] tipc: subscription refcount simplifications

2017-03-28 Thread Parthasarathy Bhuvaragan
The first patch makes the subscription refcount cleanup lockless and the second updates the subscription refcount policy. Ying Xue (2): tipc: advance the time of deleting subscription from subscriber->subscrp_list tipc: adjust the policy of holding subscription kref net/tipc/name_table.c

[PATCH net v1 1/1] tipc: fix nametbl deadlock at tipc_nametbl_unsubscribe

2017-03-21 Thread Parthasarathy Bhuvaragan
by: Jon Maloy Signed-off-by: Ying Xue Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c index 9d94e65d0894..271cd66e4b3b 100644 --- a/net/tipc/subsc

[PATCH net v1 0/6] topology server fixes for nametable soft lockup

2017-01-24 Thread Parthasarathy Bhuvaragan
scribed by patch#4. Parthasarathy Bhuvaragan (6): tipc: fix nametbl_lock soft lockup at node/link events tipc: add subscription refcount to avoid invalid delete tipc: fix connection refcount error tipc: fix nametbl_lock soft lockup at module exit tipc: ignore requests when the connection st

[PATCH net v1 4/6] tipc: fix nametbl_lock soft lockup at module exit

2017-01-24 Thread Parthasarathy Bhuvaragan
6235a527. Hence we can now revert the commit. Fixes: 333f796235a52727 ("tipc: fix a race condition leading to subscriber refcnt bug") Reported-and-Tested-by: John Thompson Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/server.c | 16 +-

[PATCH net v1 3/6] tipc: fix connection refcount error

2017-01-24 Thread Parthasarathy Bhuvaragan
ned-off-by: Parthasarathy Bhuvaragan --- net/tipc/server.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/net/tipc/server.c b/net/tipc/server.c index 215849ce453d..2e803601aa99 100644 --- a/net/tipc/server.c +++ b/net/tipc/server.c @@ -91,7 +91,8 @@ s

[PATCH net v1 1/6] tipc: fix nametbl_lock soft lockup at node/link events

2017-01-24 Thread Parthasarathy Bhuvaragan
scribe() to use the fast variants. Reported-and-Tested-by: John Thompson Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/node.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/net/tipc/node.c b/net/tipc/node.c index 9d2f4c2b0

[PATCH net v1 5/6] tipc: ignore requests when the connection state is not CONNECTED

2017-01-24 Thread Parthasarathy Bhuvaragan
Maloy Tested-by: John Thompson Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/server.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/net/tipc/server.c b/net/tipc/server.c index 826cde2c401e..04ff441b8065 100644 --- a/net/tipc/server.c +++ b/net/tipc

[PATCH net v1 2/6] tipc: add subscription refcount to avoid invalid delete

2017-01-24 Thread Parthasarathy Bhuvaragan
Thompson Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 124 ++ net/tipc/subscr.h | 1 + 2 files changed, 71 insertions(+), 54 deletions(-) diff --git a/net/tipc/subscr.c b/net/tipc

[PATCH net v1 6/6] tipc: fix cleanup at module unload

2017-01-24 Thread Parthasarathy Bhuvaragan
ed-by: Jon Maloy Tested-by: John Thompson Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/server.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/net/tipc/server.c b/net/tipc/server.c index 04ff441b8065..3cd6402e812c 100644 --- a/net/tipc/server.c +++ b/net/tipc/ser

[PATCH net v1 1/1] tipc: allocate user memory with GFP_KERNEL flag

2017-01-13 Thread Parthasarathy Bhuvaragan
with GFP_KERNEL for all user allocation. Reported-by: Rune Torgersen Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/discover.c | 4 ++-- net/tipc/link.c | 2 +- net/tipc/msg.c| 16 net/tipc/msg.h| 2 +- net/tipc/name_distr.c

[PATCH net-next v2 13/16] tipc: create TIPC_DISCONNECTING as a new sk_state

2016-11-01 Thread Parthasarathy Bhuvaragan
an error message on the connection. There is no functional change in this commit. Signed-off-by: Parthasarathy Bhuvaragan --- v2: set TIPC_DISCONNECTING to TCP_CLOSE_WAIT. --- net/tipc/socket.c | 39 --- 1 file changed, 24 insertions(+), 15 deletions(-) diff

[PATCH net-next v2 10/16] tipc: create TIPC_LISTEN as a new sk_state

2016-11-01 Thread Parthasarathy Bhuvaragan
igned-off-by: Parthasarathy Bhuvaragan --- v2: set TIPC_LISTEN value to TCP_LISTEN to permit the usage of generic sk_* helpers as suggested by Eric Dumazet. --- net/tipc/socket.c | 62 ++- 1 file changed, 43 insertions(+), 19 deletions(-) diff --gi

[PATCH net-next v2 11/16] tipc: create TIPC_ESTABLISHED as a new sk_state

2016-11-01 Thread Parthasarathy Bhuvaragan
ing state TIPC_CONN_OK, we create a new state TIPC_ESTABLISHED. There is no functional change in this commit. Signed-off-by: Parthasarathy Bhuvaragan --- v2: remove TIPC_PROBING state and replace it with probe_unacked flag. --- net/tipc/socket.c | 18 +++--- 1 file changed, 11 inserti

[PATCH net-next v2 16/16] tipc: remove SS_CONNECTED sock state

2016-11-01 Thread Parthasarathy Bhuvaragan
IPC_ESTABLISHED | | +--+ | ^ | | | | | | v | ++ | | TIPC_DISCONNECTING |<--+ ++ Signed-off

[PATCH net-next v2 12/16] tipc: create TIPC_OPEN as a new sk_state

2016-11-01 Thread Parthasarathy Bhuvaragan
In this commit, we create a new tipc socket state TIPC_OPEN in sk_state. We primarily replace the SS_UNCONNECTED sock->state with TIPC_OPEN. Signed-off-by: Parthasarathy Bhuvaragan --- v2: TIPC_OPEN is set to the default sk_state TCP_CLOSE. --- net/tipc/socket.c |

[PATCH net-next v2 15/16] tipc: create TIPC_CONNECTING as a new sk_state

2016-11-01 Thread Parthasarathy Bhuvaragan
In this commit, we create a new tipc socket state TIPC_CONNECTING by primarily replacing the SS_CONNECTING with TIPC_CONNECTING. There is no functional change in this commit. Signed-off-by: Parthasarathy Bhuvaragan --- v2: set TIPC_CONNECTING to TCP_SYN_SENT. --- net/tipc/socket.c | 60

[PATCH net-next v2 09/16] tipc: remove socket state SS_READY

2016-11-01 Thread Parthasarathy Bhuvaragan
Until now, tipc socket state SS_READY declares that the socket is a connectionless socket. In this commit, we remove the state SS_READY and replace it with a condition which returns true for datagram / connectionless sockets. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy

[PATCH net-next v2 14/16] tipc: remove SS_DISCONNECTING state

2016-11-01 Thread Parthasarathy Bhuvaragan
In this commit, we replace the references to SS_DISCONNECTING with the combination of sk_state TIPC_DISCONNECTING and flags set in sk_shutdown. We introduce a new function _tipc_shutdown(), which provides the common code required by tipc_release() and tipc_shutdown(). Signed-off-by: Parthasarathy

[PATCH net-next v2 08/16] tipc: remove probing_intv from tipc_sock

2016-11-01 Thread Parthasarathy Bhuvaragan
functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 7b6a1847cf8a..1b1aa941cd06 100644

[PATCH net-next v2 06/16] tipc: remove tsk->connected for connectionless sockets

2016-11-01 Thread Parthasarathy Bhuvaragan
e is determined by tsk->peer.family, instead of tsk->connected. - tipc_connect(), remove set/unset of tsk->connected. Hence tsk->connected is no longer used for connectionless sockets. There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off

[PATCH net-next v2 07/16] tipc: remove tsk->connected from tipc_sock

2016-11-01 Thread Parthasarathy Bhuvaragan
ck and derive socket connection status from the following condition: sock->state == SS_CONNECTED => tsk->connected There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 36 +++-

[PATCH net-next v2 00/16] tipc: socket layer improvements

2016-11-01 Thread Parthasarathy Bhuvaragan
lace the TIPC_CLOSING state in v1 with sk_shutdown flag in #14. - introduce __tipc_shutdown() to avoid code duplication in #14. Parthasarathy Bhuvaragan (16): tipc: return early for non-blocking sockets at link congestion tipc: wakeup sleeping users at disconnect tipc: set kern=0 in

[PATCH net-next v2 05/16] tipc: rename tsk->remote to tsk->peer for consistent naming

2016-11-01 Thread Parthasarathy Bhuvaragan
t. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index c543ae6cbf65..0546556d3517 100644 --- a/net/tipc/socket.c +++ b

[PATCH net-next v2 03/16] tipc: set kern=0 in sk_alloc() during tipc_accept()

2016-11-01 Thread Parthasarathy Bhuvaragan
Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index cd01deb1da9c..82aec2eb8497 100644 --- a/net/tipc/socket.c +++ b/net/tipc/socket.c @@ -2093,7 +2093,7 @@ static int tipc_a

[PATCH net-next v2 01/16] tipc: return early for non-blocking sockets at link congestion

2016-11-01 Thread Parthasarathy Bhuvaragan
AGAIN, we exhaust the memory. In this commit, we return immediately at stream/mcast send() for non-blocking sockets. Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/net/tipc/socket.c b/net/tipc/socket.c

[PATCH net-next v2 04/16] tipc: rename struct tipc_skb_cb member handle to bytes_read

2016-11-01 Thread Parthasarathy Bhuvaragan
In this commit, we rename handle to bytes_read indicating the purpose of the member. Signed-off-by: Parthasarathy Bhuvaragan --- v2: Remove unnecessary cast and parenthesis as suggested by David S. Miller. --- net/tipc/msg.h| 2 +- net/tipc/socket.c | 18 ++ 2 files changed

[PATCH net-next v2 02/16] tipc: wakeup sleeping users at disconnect

2016-11-01 Thread Parthasarathy Bhuvaragan
connection is being terminated, we fail to wakeup that socket. In this commit, we wakeup sleeping sockets at connection termination. Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/tipc/socket.c b/net/tipc

Re: [PATCH net-next v1 13/16] tipc: create TIPC_DISCONNECTING as a new sk_state

2016-10-28 Thread Parthasarathy Bhuvaragan
On 10/27/2016 05:03 PM, Eric Dumazet wrote: On Thu, 2016-10-27 at 16:22 +0200, Parthasarathy Bhuvaragan wrote: In this commit, we create a new tipc socket state TIPC_DISCONNECTING in sk_state. TIPC_DISCONNECTING is replacing the socket connection status update using SS_DISCONNECTING

[PATCH net-next v1 10/16] tipc: create TIPC_LISTEN as a new sk_state

2016-10-27 Thread Parthasarathy Bhuvaragan
by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 7 ++ net/tipc/socket.c | 59 --- 2 files changed, 47 insertions(+), 19 deletions(-) diff --git a/include/uapi/linux/tipc.h b/includ

[PATCH net-next v1 01/16] tipc: return early for non-blocking sockets at link congestion

2016-10-27 Thread Parthasarathy Bhuvaragan
AGAIN, we exhaust the memory. In this commit, we return immediately at stream/mcast send() for non-blocking sockets. Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/net/tipc/socket.c b/net/tipc/socket.c

[PATCH net-next v1 04/16] tipc: rename struct tipc_skb_cb member handle to bytes_read

2016-10-27 Thread Parthasarathy Bhuvaragan
In this commit, we rename handle to bytes_read indicating the purpose of the member. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/msg.h| 2 +- net/tipc/socket.c | 18 ++ 2 files changed, 11 insertions(+), 9 deletions(-) diff

[PATCH net-next v1 00/16] tipc: socket layer improvements

2016-10-27 Thread Parthasarathy Bhuvaragan
---+++ | TIPC_CLOSING |<---| TIPC_DISCONNECTING | +--+++ NOTE: This is just a base refractoring required for socket diagnostics. TIPC socket diagnostics support will be introduced in a later series. Parthasarathy Bhuvaragan (16): tip

[PATCH net-next v1 06/16] tipc: remove tsk->connected for connectionless sockets

2016-10-27 Thread Parthasarathy Bhuvaragan
e is determined by tsk->peer.family, instead of tsk->connected. - tipc_connect(), remove set/unset of tsk->connected. Hence tsk->connected is no longer used for connectionless sockets. There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off

[PATCH net-next v1 09/16] tipc: remove socket state SS_READY

2016-10-27 Thread Parthasarathy Bhuvaragan
Until now, tipc socket state SS_READY declares that the socket is a connectionless socket. In this commit, we remove the state SS_READY and replace it with a condition which returns true for datagram / connectionless sockets. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy

[PATCH net-next v1 12/16] tipc: create TIPC_OPEN as a new sk_state

2016-10-27 Thread Parthasarathy Bhuvaragan
In this commit, we create a new tipc socket state TIPC_OPEN in sk_state. We primarily replace the SS_UNCONNECTED sock->state with TIPC_OPEN. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 1 + net/tipc/socket.c |

[PATCH net-next v1 02/16] tipc: wakeup sleeping users at disconnect

2016-10-27 Thread Parthasarathy Bhuvaragan
connection is being terminated, we fail to wakeup that socket. In this commit, we wakeup sleeping sockets at connection termination. Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/tipc/socket.c b/net/tipc

[PATCH net-next v1 14/16] tipc: create TIPC_CLOSING as a new sk_state

2016-10-27 Thread Parthasarathy Bhuvaragan
There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 1 + net/tipc/socket.c | 19 --- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/include/uapi/li

[PATCH net-next v1 11/16] tipc: create TIPC_PROBING/TIPC_ESTABLISHED as new sk_states

2016-10-27 Thread Parthasarathy Bhuvaragan
is set to TIPC_ESTABLISHED instead of TIPC_CONN_OK. There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 2 ++ net/tipc/socket.c | 23 +-- 2 files changed,

[PATCH net-next v1 16/16] tipc: remove SS_CONNECTED sock state

2016-10-27 Thread Parthasarathy Bhuvaragan
y: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 100 +- 1 file changed, 47 insertions(+), 53 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 7702acf0bfab..2a095fa6bff7 100644 --- a/net/tipc/socke

[PATCH net-next v1 15/16] tipc: create TIPC_CONNECTING as a new sk_state

2016-10-27 Thread Parthasarathy Bhuvaragan
In this commit, we create a new tipc socket state TIPC_CONNECTING by primarily replacing the SS_CONNECTING with TIPC_CONNECTING. There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 1

[PATCH net-next v1 08/16] tipc: remove probing_intv from tipc_sock

2016-10-27 Thread Parthasarathy Bhuvaragan
functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 8299964cd373..82e06488de08 100644

[PATCH net-next v1 13/16] tipc: create TIPC_DISCONNECTING as a new sk_state

2016-10-27 Thread Parthasarathy Bhuvaragan
an error message on the connection. There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 1 + net/tipc/socket.c | 39 +++ 2 files changed, 24

[PATCH net-next v1 07/16] tipc: remove tsk->connected from tipc_sock

2016-10-27 Thread Parthasarathy Bhuvaragan
ck and derive socket connection status from the following condition: sock->state == SS_CONNECTED => tsk->connected There is no functional change in this commit. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 36 +++-

[PATCH net-next v1 05/16] tipc: rename tsk->remote to tsk->peer for consistent naming

2016-10-27 Thread Parthasarathy Bhuvaragan
t. Acked-by: Ying Xue Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 6e3774a7c831..8bc9c32c41b5 100644 --- a/net/tipc/socket.c +++ b

[PATCH net-next v1 03/16] tipc: set kern=0 in sk_alloc() during tipc_accept()

2016-10-27 Thread Parthasarathy Bhuvaragan
Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/tipc/socket.c b/net/tipc/socket.c index cd01deb1da9c..82aec2eb8497 100644 --- a/net/tipc/socket.c +++ b/net/tipc/socket.c @@ -2093,7 +2093,7 @@ static int tipc_a

[PATCH iproute2 net-next v1 0/7] tipc: updates for neighbour monitor

2016-09-12 Thread Parthasarathy Bhuvaragan
We add configuration support for the new link monitoring attributes. Parthasarathy Bhuvaragan (7): tipc: remove dead code tipc: add link monitor set threshold tipc: add link monitor get threshold tipc: add link monitor summary tipc: refractor bearer to facilitate link monitor tipc

[PATCH iproute2 net-next v1 1/7] tipc: remove dead code

2016-09-12 Thread Parthasarathy Bhuvaragan
remove dead code and a newline. Signed-off-by: Parthasarathy Bhuvaragan --- tipc/link.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/tipc/link.c b/tipc/link.c index 061b1c534389..8bdc98224d39 100644 --- a/tipc/link.c +++ b/tipc/link.c @@ -90,7 +90,6 @@ static int link_get_cb(const

[PATCH iproute2 net-next v1 6/7] tipc: add link monitor list

2016-09-12 Thread Parthasarathy Bhuvaragan
Acked-by: Jon Maloy Tested-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- tipc/link.c | 237 1 file changed, 237 insertions(+) diff --git a/tipc/link.c b/tipc/link.c index df93409f2173..0b5c0491a35f 100644 --- a/tipc/link.c

[PATCH iproute2 net-next v1 5/7] tipc: refractor bearer to facilitate link monitor

2016-09-12 Thread Parthasarathy Bhuvaragan
In this commit, we: 1. Export print_bearer_media() 2. Move the bearer name handling from nl_add_bearer_name() into a new function cmd_get_unique_bearer_name(). These exported functions will be used by link monitor used in subsequent commits. Signed-off-by: Parthasarathy Bhuvaragan --- tipc

[PATCH iproute2 net-next v1 3/7] tipc: add link monitor get threshold

2016-09-12 Thread Parthasarathy Bhuvaragan
-off-by: Parthasarathy Bhuvaragan --- tipc/link.c | 56 +++- 1 file changed, 55 insertions(+), 1 deletion(-) diff --git a/tipc/link.c b/tipc/link.c index 3469cd302469..3f0c32106772 100644 --- a/tipc/link.c +++ b/tipc/link.c @@ -534,12 +534,65

[PATCH iproute2 net-next v1 7/7] tipc: update man page for link monitor

2016-09-12 Thread Parthasarathy Bhuvaragan
Add description for the new link monitor commands. Signed-off-by: Parthasarathy Bhuvaragan --- man/man8/tipc-link.8 | 104 +++ 1 file changed, 104 insertions(+) diff --git a/man/man8/tipc-link.8 b/man/man8/tipc-link.8 index 2ee03a0bd96e

[PATCH iproute2 net-next v1 4/7] tipc: add link monitor summary

2016-09-12 Thread Parthasarathy Bhuvaragan
algorithm overlapping-ring $ tipc link monitor summary -h Usage: tipc monitor summary Acked-by: Jon Maloy Tested-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- tipc/link.c | 47 ++- 1 file changed, 46 insertions(+), 1 deletion(-) diff

[PATCH iproute2 net-next v1 2/7] tipc: add link monitor set threshold

2016-09-12 Thread Parthasarathy Bhuvaragan
Tested-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- tipc/link.c | 69 - 1 file changed, 68 insertions(+), 1 deletion(-) diff --git a/tipc/link.c b/tipc/link.c index 8bdc98224d39..3469cd302469 100644 --- a/tipc/link.c +++ b

[PATCH net v1] tipc: fix random link resets while adding a second bearer

2016-09-01 Thread Parthasarathy Bhuvaragan
r reached leading to link timeout. In this commit, we adjust the size of name distributor message so that they can be tunnelled. Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/name_distr.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/net

[PATCH net v1 1/1] tipc: fix variable dereference before NULL check

2016-08-10 Thread Parthasarathy Bhuvaragan
In this commit, we check for a valid monitor before proceeding with any other operation. Fixes: cf6f7e1d5109 ("tipc: dump monitor attributes") Reported-by: Dan Carpenter Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/monitor.c | 3 ++- 1 file changed, 2 insertions(+), 1 dele

[PATCH net-next v2 2/5] tipc: make cluster size threshold for monitoring configurable

2016-07-25 Thread Parthasarathy Bhuvaragan
In this commit, we introduce support to configure the minimum threshold to activate the new link monitoring algorithm. Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc_netlink.h | 11 +++ net/tipc/monitor.c| 12 net

[PATCH net-next v2 0/5] tipc: netlink updates for neighbour monitor

2016-07-25 Thread Parthasarathy Bhuvaragan
This series contains the updates to configure and read the attributes for neighbour monitor. v2: rebase on top of net-next Parthasarathy Bhuvaragan (5): tipc: introduce constants for tipc address validation tipc: make cluster size threshold for monitoring configurable tipc: get monitor

[PATCH net-next v2 5/5] tipc: dump monitor attributes

2016-07-25 Thread Parthasarathy Bhuvaragan
Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc_netlink.h | 25 +++ net/tipc/monitor.c| 133 ++ net/tipc/monitor.h| 6 ++ net/tipc/netlink.c| 7 ++ net/tipc/node.c

[PATCH net-next v2 4/5] tipc: add a function to get the bearer name

2016-07-25 Thread Parthasarathy Bhuvaragan
Introduce a new function to get the bearer name from its id. This is used in subsequent commit. Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/bearer.c | 21 + net/tipc/bearer.h | 1 + 2 files changed, 22 insertions(+) diff --git a/net/tipc

[PATCH net-next v2 1/5] tipc: introduce constants for tipc address validation

2016-07-25 Thread Parthasarathy Bhuvaragan
In this commit, we introduce defines for tipc address size, offset and mask specification for Zone.Cluster.Node. There is no functional change in this commit. Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc.h | 30 ++ net

[PATCH net-next v2 3/5] tipc: get monitor threshold for the cluster

2016-07-25 Thread Parthasarathy Bhuvaragan
In this commit, we add support to fetch the configured cluster monitoring threshold. Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- include/uapi/linux/tipc_netlink.h | 1 + net/tipc/monitor.c| 7 ++ net/tipc/monitor.h| 2 ++ net/tipc

[PATCH net-next v1 0/5] tipc: netlink updates for neighbour monitor

2016-07-21 Thread Parthasarathy Bhuvaragan
This series contains the updates to configure and read the attributes for neighbour monitor. Parthasarathy Bhuvaragan (5): tipc: introduce constants for tipc address validation tipc: make cluster size threshold for monitoring configurable tipc: get monitor threshold for the cluster tipc

[PATCH net-next v1 1/5] tipc: introduce constants for tipc address validation

2016-07-21 Thread Parthasarathy Bhuvaragan
In this commit, we introduce defines for tipc address size, offset and mask specification for Zone.Cluster.Node. There is no functional change in this commit. Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- include/uapi/linux/tipc.h | 30 ++ net

[PATCH net-next v1 4/5] tipc: add a function to get the bearer name

2016-07-21 Thread Parthasarathy Bhuvaragan
Introduce a new function to get the bearer name from its id. This is used in subsequent commit. Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- net/tipc/bearer.c | 21 + net/tipc/bearer.h | 1 + 2 files changed, 22 insertions(+) diff --git a/net/tipc

[PATCH net-next v1 5/5] tipc: dump monitor attributes

2016-07-21 Thread Parthasarathy Bhuvaragan
: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- include/uapi/linux/tipc_netlink.h | 25 +++ net/tipc/monitor.c| 133 ++ net/tipc/monitor.h| 6 ++ net/tipc/netlink.c| 7 ++ net/tipc/node.c

[PATCH net-next v1 3/5] tipc: get monitor threshold for the cluster

2016-07-21 Thread Parthasarathy Bhuvaragan
In this commit, we add support to fetch the configured cluster monitoring threshold. Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- include/uapi/linux/tipc_netlink.h | 1 + net/tipc/monitor.c| 7 ++ net/tipc/monitor.h| 2 ++ net/tipc

[PATCH net-next v1 2/5] tipc: make cluster size threshold for monitoring configurable

2016-07-21 Thread Parthasarathy Bhuvaragan
In this commit, we introduce support to configure the minimum threshold to activate the new link monitoring algorithm. Signed-off-by: Parthasarathy Bhuvaragan Reviewed-by: Jon Maloy --- include/uapi/linux/tipc_netlink.h | 11 +++ net/tipc/monitor.c| 12 net

[PATCH net-next v1 1/1] tipc: fix stale links after re-enabling bearer

2016-04-21 Thread Parthasarathy Bhuvaragan
correctly. Fixes: 42b18f605fea ("tipc: refactor function tipc_link_timeout()") Acked-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/link.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/net/tipc/link.c b/net/tipc/link.c index 2e28a7d7e802.

[PATCH net-next v1 1/1] tipc: fix a race condition leading to subscriber refcnt bug

2016-04-12 Thread Parthasarathy Bhuvaragan
during connection release procedure rather than connection shutdown procedure. Signed-off-by: Parthasarathy Bhuvaragan Acked-by: Ying Xue --- net/tipc/server.c | 19 +-- net/tipc/server.h | 4 ++-- net/tipc/subscr.c | 4 ++-- 3 files changed, 17 insertions(+), 10 deletions

[PATCH net-next v1 1/1] tipc: Revert "tipc: use existing sk_write_queue for outgoing packet chain"

2016-03-04 Thread Parthasarathy Bhuvaragan
path+0x16/0x1b In this commit, we maintain the skb list always in the stack. Signed-off-by: Parthasarathy Bhuvaragan Acked-by: Ying Xue Acked-by: Jon Maloy --- net/tipc/socket.c | 33 +++-- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/net/tipc/sock

[PATCH net v1 1/1] tipc: fix nullptr crash during subscription cancel

2016-03-03 Thread Parthasarathy Bhuvaragan
ription is passed to tipc_nametbl_subscribe() resulting in exception. In this commit, we call tipc_nametbl_subscribe() only for a valid subscription. Fixes: 4d5cfcba2f6e ('tipc: fix connection abort during subscription cancel') Reported-by: Anders Widell Signed-off-by: Parthasarathy Bhuva

[PATCH net v1 1/1] tipc: Revert "tipc: use existing sk_write_queue for outgoing packet chain"

2016-03-01 Thread Parthasarathy Bhuvaragan
ll_fastpath+0x16/0x1b In this commit, we maintain the skb list always in the stack. Signed-off-by: Parthasarathy Bhuvaragan Acked-by: Ying Xue Acked-by: Jon Maloy --- net/tipc/socket.c | 33 +++-- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/net/tip

[PATCH net-next v2 07/10] tipc: hold subscriber->lock for tipc_nametbl_subscribe()

2016-02-02 Thread Parthasarathy Bhuvaragan
pe of subscriber lock Acked-by: Ying Xue Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c index 24d2c8128bac..e4ebbc161e42 100644 --- a/net/tipc/subscr.c

[PATCH net-next v2 03/10] tipc: remove struct tipc_name_seq from struct tipc_subscription

2016-02-02 Thread Parthasarathy Bhuvaragan
: Parthasarathy Bhuvaragan --- net/tipc/name_table.c | 14 ++ net/tipc/subscr.c | 33 +++-- net/tipc/subscr.h | 6 -- 3 files changed, 37 insertions(+), 16 deletions(-) diff --git a/net/tipc/name_table.c b/net/tipc/name_table.c index 91fce70291a8

[PATCH net-next v2 08/10] tipc: protect tipc_subscrb_get() with subscriber spin lock

2016-02-02 Thread Parthasarathy Bhuvaragan
iption to subscriber's subscription list. Acked-by: Ying Xue Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c index e4ebbc161e42..7d226ecb0490 100644

[PATCH net-next v2 06/10] tipc: fix connection abort when receiving invalid cancel request

2016-02-02 Thread Parthasarathy Bhuvaragan
the request is illegal, which terminates this connection. In this commit we determine the endianness by including TIPC_SUB_CANCEL, which will set swap correctly and the request is processed as a cancellation request. Acked-by: Ying Xue Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvarag

[PATCH net-next v2 10/10] tipc: use alloc_ordered_workqueue() instead of WQ_UNBOUND w/ max_active = 1

2016-02-02 Thread Parthasarathy Bhuvaragan
this commit we replace alloc_workqueue() with more readable alloc_ordered_workqueue(). Acked-by: Ying Xue Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/server.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/tipc/server.c b/net/tipc/serv

[PATCH net-next v2 09/10] tipc: donot create timers if subscription timeout = TIPC_WAIT_FOREVER

2016-02-02 Thread Parthasarathy Bhuvaragan
: Ying Xue Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 14 +++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c index 7d226ecb0490..22963cafd5ed 100644 --- a/net/tipc/subscr.c +++ b/net/tipc

[PATCH net-next v2 02/10] tipc: remove filter and timeout elements from struct tipc_subscription

2016-02-02 Thread Parthasarathy Bhuvaragan
tipc_subscription and replace them with elements from struct tipc_subscr. Acked-by: Ying Xue Reviewed-by: Jon Maloy Signed-off-by: Parthasarathy Bhuvaragan --- net/tipc/subscr.c | 15 --- net/tipc/subscr.h | 5 - 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/net/tipc

  1   2   >