login
Header Space

 
 

Re: sockets affected by IPsec always block (2.6.23)

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: <stefan@...>
Cc: <herbert@...>, <simon@...>, <linux-kernel@...>, <netdev@...>
Date: Thursday, December 6, 2007 - 7:13 am

From: Stefan Rompf <stefan@loplof.de>
Date: Thu, 6 Dec 2007 11:56:48 +0100


I meant whether "immediately" mean in reference to socket
state or includes auxiliary things like route lookups.

When you do a non-blocking write on a socket, things like
memory allocations can block, potentially for a long time.
It is an example where there are definite boundaries to where
the non-blocking'ness applies.

And therefore it is not so cut and dry and you present this
issue.


And that connect() call can hang for a long time due to any memory
allocation done in the connect() path.

You are not avoiding blocking by setting O_NONBLOCK on the socket, it
is quite foolhardy to think that it does so unilaterally.

And that's why this is a grey area.  Why is waiting for memory
allocation on a O_NONBLOCK socket OK but waiting for IPSEC route
resolution is not?
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
sockets affected by IPsec always block (2.6.23), Simon Arlott, (Tue Dec 4, 2:53 pm)
Re: sockets affected by IPsec always block (2.6.23), Herbert Xu, (Tue Dec 4, 8:12 pm)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Wed Dec 5, 2:30 am)
Re: sockets affected by IPsec always block (2.6.23), Herbert Xu, (Wed Dec 5, 2:51 am)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Wed Dec 5, 2:39 pm)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Wed Dec 5, 10:25 pm)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Thu Dec 6, 4:49 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Thu Dec 6, 4:53 am)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Thu Dec 6, 6:56 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Thu Dec 6, 7:13 am)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Thu Dec 6, 7:35 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Thu Dec 6, 7:39 am)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Thu Dec 6, 8:30 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Thu Dec 6, 9:55 am)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Thu Dec 6, 10:31 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Thu Dec 6, 11:20 pm)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Fri Dec 7, 5:29 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Wed Dec 5, 3:12 am)
Re: sockets affected by IPsec always block (2.6.23), Stefan Rompf, (Wed Dec 5, 2:42 pm)
Re: sockets affected by IPsec always block (2.6.23), Herbert Xu, (Wed Dec 5, 3:16 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Wed Dec 5, 3:34 am)
Re: sockets affected by IPsec always block (2.6.23), Herbert Xu, (Wed Dec 5, 3:39 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Wed Dec 5, 5:55 am)
Re: sockets affected by IPsec always block (2.6.23), Herbert Xu, (Wed Dec 5, 5:57 am)
Re: sockets affected by IPsec always block (2.6.23), David Miller, (Wed Dec 5, 2:06 am)
speck-geostationary