DragonFly kernel List (threaded) for 2008-08
DragonFly BSD
DragonFly kernel List (threaded) for 2008-08
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: [netmp] socket accesses


From: Aggelos Economopoulos <aoiko@xxxxxxxxxxxxxx>
Date: Mon, 18 Aug 2008 01:31:14 +0300

On Saturday 09 August 2008, Matthew Dillon wrote:
[...]
>     Ok, here are my suggestions:
[...]
>     CANTRCVMORE:
> 
> 	* Set by both sides.  Should be ok as long as any races are resolved.
> 	  In the case of userland, it could set CANTRCVMORE and send an
> 	  async message to the protocol stack.
> 
> 	  In the case of the protocol stack, it could set CANTRCVMORE and
> 	  then drain any wait-style messages (such as sent by soreceive()
> 	  when it blocks via ssb_wait(), using the new idea for ssb_wait()).

[...]

>     The so_state flags themselves would have to be set and cleared with
>     atomic ops.  Any situation which requires notifying the protocol stack,
>     such as when userland sets CANTRCVMORE, can be done with a 'checkstate'
>     style message to the protocol stack.  The message would not contain the
>     flag, userland would simply set the flag and then tell the protocol
>     stack to check its flags state and do whatever needs to be done.

I'm not sure what the protocol thread would have to do in this case. Isn't it
enough to just have it set the relevant flag in response to the message?

Aggelos



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]