Netdev List
 help / color / mirror / Atom feed
* [PATCH net-next 0/5] tipc: align TIPC behaviours of waiting for events with other stacks
@ 2014-01-17  1:50 Ying Xue
  2014-01-17  1:50 ` [PATCH net-next 1/5] tipc: standardize connect routine Ying Xue
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: Ying Xue @ 2014-01-17  1:50 UTC (permalink / raw)
  To: davem; +Cc: jon.maloy, netdev, Paul.Gortmaker, tipc-discussion

Comparing the current implementations of waiting for events in TIPC
socket layer with other stacks, TIPC's behaviour is very different
because wait_event_interruptible_timeout()/wait_event_interruptible()
are always used by TIPC to wait for events while relevant socket or
port variables are fed to them as their arguments. As socket lock has
to be released temporarily before the two routines of waiting for
events are called, their arguments associated with socket or port
structures are out of socket lock protection. This might cause
serious issues where the process of calling socket syscall such as
sendsmg(), connect(), accept(), and recvmsg(), cannot be waken up
at all even if proper event arrives or improperly be woken up
although the condition of waking up the process is not satisfied
in practice.

Therefore, aligning its behaviours with similar functions implemented
in other stacks, for instance, sk_stream_wait_connect() and
inet_csk_wait_for_connect() etc, can avoid above risks for us.

Ying Xue (5):
  tipc: standardize connect routine
  tipc: standardize accept routine
  tipc: standardize sendmsg routine of connectionless socket
  tipc: standardize sendmsg routine of connected socket
  tipc: standardize recvmsg routine

 net/tipc/socket.c |  296 +++++++++++++++++++++++++++++++++--------------------
 1 file changed, 186 insertions(+), 110 deletions(-)

-- 
1.7.9.5


------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For
Critical Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today. 
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2014-01-17  3:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-17  1:50 [PATCH net-next 0/5] tipc: align TIPC behaviours of waiting for events with other stacks Ying Xue
2014-01-17  1:50 ` [PATCH net-next 1/5] tipc: standardize connect routine Ying Xue
2014-01-17  1:50 ` [PATCH net-next 2/5] tipc: standardize accept routine Ying Xue
2014-01-17  1:50 ` [PATCH net-next 3/5] tipc: standardize sendmsg routine of connectionless socket Ying Xue
2014-01-17  1:50 ` [PATCH net-next 4/5] tipc: standardize sendmsg routine of connected socket Ying Xue
2014-01-17  1:50 ` [PATCH net-next 5/5] tipc: standardize recvmsg routine Ying Xue
2014-01-17  3:11 ` [PATCH net-next 0/5] tipc: align TIPC behaviours of waiting for events with other stacks David Miller
2014-01-17  3:20   ` Jon Maloy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox