The next "struct seq" introduced in patch 4 should be useful outside dpif-netdev; it is a general-purpose synchronization data structure.
Ben Pfaff (5): ovs-thread: New function xpthread_setspecific(). ovs-thread: Add support for globally visible per-thread data. ovs-thread: New function ovsthread_id_self() seq: New module for race-free, pollable, thread-safe sequence number. dpif-netdev: Avoid race in dpif_netdev_port_poll_wait() using seq object. lib/automake.mk | 2 + lib/dpif-netdev.c | 29 +++--- lib/ovs-thread.c | 34 ++++++- lib/ovs-thread.h | 116 ++++++++++++++++++++---- lib/poll-loop.c | 5 +- lib/random.c | 2 +- lib/seq.c | 255 +++++++++++++++++++++++++++++++++++++++++++++++++++++ lib/seq.h | 89 +++++++++++++++++++ lib/timeval.c | 2 +- lib/util.c | 4 +- lib/vlog.c | 2 +- 11 files changed, 501 insertions(+), 39 deletions(-) create mode 100644 lib/seq.c create mode 100644 lib/seq.h -- 1.7.10.4 _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev