Re: [ovs-dev] [PATCH 3/5] lib/cmap: Use non-atomic access to hash.

2014-10-06 Thread Ben Pfaff
On Wed, Sep 24, 2014 at 11:31:45AM -0700, Jarno Rajahalme wrote: > We use the 'counter' as a "lock" providing acquire-release > semantics. Therefore we can use normal, non-atomic access to the > memory accesses between the atomic accesses to 'counter'. The > cmap_node.next needs to be RCU, so tha

[ovs-dev] [PATCH 3/5] lib/cmap: Use non-atomic access to hash.

2014-09-24 Thread Jarno Rajahalme
We use the 'counter' as a "lock" providing acquire-release semantics. Therefore we can use normal, non-atomic access to the memory accesses between the atomic accesses to 'counter'. The cmap_node.next needs to be RCU, so that can not be changed. Also rearrange code to benefit from the fact that