[ovs-dev] Threaded userspace datapath

Ben Pfaff blp at nicira.com
Mon Aug 27 00:00:22 UTC 2012


On Fri, Aug 24, 2012 at 10:25:02AM +0200, Giuseppe Lettieri wrote:
> Il 20/08/2012 20:48, Ed Maste ha scritto:
> >>3. The datapath thread waits in poll() with each port's file descriptor in
> >>>the fd array.  However there's currently no fd to signal a bridge
> >>>reconfiguration, so the poll() has to timeout before the thread will pick up
> >>>the new config on the next time through its loop.
> 
> We are considering to add the notification in dpif_netdev_run(), a
> callback which is now empty in the #ifdef THREADED case. According
> to our tests this solves the problem in practice, but we are worried
> that it may be a misuse of the interface, since the corresponding
> dpif_netdev_wait() callback would still be empty. Any comment would
> be much appreciated.

There's no inherent reason that a "wait" function has to be nonempty if
the corresponding "run" function is nonempty.  The question is simply
whether the poll loop will wake up when "run" needs to do some work, and
if you're confident that that will happen (I don't have enough context
here to check myself) then that's fine.



More information about the dev mailing list