guarded-list: New data structure for thread-safe queue.
authorBen Pfaff <blp@nicira.com>
Fri, 13 Sep 2013 00:42:23 +0000 (17:42 -0700)
committerBen Pfaff <blp@nicira.com>
Fri, 13 Sep 2013 00:43:55 +0000 (17:43 -0700)
commit050678819a46b12cdbf2021545c61631ce5041e9
tree6b8e60cc499cfa07d02393f7d88bb7628a93e005
parenta2143702724647df8a9aef570982738dd3721af0
guarded-list: New data structure for thread-safe queue.

We already had queues that were suitable for replacement by this data
structure, and I intend to add another one later on.

flow_miss_batch_ofproto_destroyed() did not work well with the guarded-list
structure (it required either adding a lot more functions or breaking the
abstraction) so I changed the caller to just use udpif_revalidate().

Checking reval_seq at the end of handle_miss_upcalls() also didn't work
well with the abstraction, so I decided that since this was a corner case
anyway it would be acceptable to just drop those in flow_miss_batch_next().

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
lib/automake.mk
lib/guarded-list.c [new file with mode: 0644]
lib/guarded-list.h [new file with mode: 0644]
ofproto/ofproto-dpif-upcall.c
ofproto/ofproto-dpif-upcall.h
ofproto/ofproto-dpif.c