Thanks for the below explanations. Please send out the next version.

Regards,
Ying

-----Original Message-----
From: Parthasarathy Bhuvaragan [mailto:parthasarathy.bhuvara...@ericsson.com] 
Sent: Wednesday, August 03, 2016 10:57 PM
To: Xue, Ying; tipc-discussion@lists.sourceforge.net; jon.ma...@ericsson.com; 
ma...@donjonn.com; erik.hu...@gmail.com
Subject: Re: [RFC PATCH v1 09/12] tipc: create TIPC_UNCONNECTED as a new 
sk_state

On 08/02/2016 11:16 AM, Xue, Ying wrote:
> @@ -1684,17 +1687,22 @@ static bool filter_connect(struct tipc_sock *tsk, 
> struct sk_buff *skb)
>               msg_set_dest_droppable(hdr, 1);
>               return false;
>  
> -     case SS_UNCONNECTED:
> +     case SS_DISCONNECTING:
> +             break;
> +     }
>  
> +     switch (sk->sk_state) {
> +     case TIPC_UNCONNECTED:
> +             break;
>
> If the TIPC_UNCONNECTED case condition is broken, it means that 
> filter_connect () will return false. As a result, SYN msg would be rejected 
> when socket state is in TIPC_UNCONNECTED. If so, I don't understand how a 
> client stream socket can receive SYN msg.
[partha] We process sock->state intentionally before sk->sk_state. The client 
stream socket has its sock->state set to SS_CONNECTING, hence will consume the 
SYN msg from server and filter_connect() would return true. The case for 
TIPC_UNCONNECTED exists just to prevent an error message "Unknown sk_state..".
> Regards,
> Ying
>
>

------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity 
planning reports. http://sdm.link/zohodev2dev
_______________________________________________
tipc-discussion mailing list
tipc-discussion@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tipc-discussion

Reply via email to