X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fovs-atomic.h;h=01ac8c4f7afbef07daf7c05974652ebc6909b83d;hb=0ef165ecb57943e17a8ee8270df68ffb8d032e29;hp=62cd258620889d84574356b590f2a9360c1a3dcf;hpb=6a36690c200a08dfbd5648269e3e1ab837d1b726;p=sliver-openvswitch.git diff --git a/lib/ovs-atomic.h b/lib/ovs-atomic.h index 62cd25862..01ac8c4f7 100644 --- a/lib/ovs-atomic.h +++ b/lib/ovs-atomic.h @@ -102,15 +102,6 @@ * ... * atomic_init(&ai, 123); * - * C11 does not hav an destruction function for atomic types, but some - * implementations of the OVS atomics do need them. Thus, the following - * function is provided for destroying non-static atomic objects (A is any - * atomic type): - * - * void atomic_destroy(A *object); - * - * Destroys 'object'. - * * * Barriers * ======== @@ -224,19 +215,7 @@ * ATOMIC_FLAG_INIT is an initializer for atomic_flag. The initial state is * "clear". * - * C11 does not have an initialization or destruction function for atomic_flag, - * because implementations should not need one (one may simply - * atomic_flag_clear() an uninitialized atomic_flag), but some implementations - * of the OVS atomics do need them. Thus, the following two functions are - * provided for initializing and destroying non-static atomic_flags: - * - * void atomic_flag_init(volatile atomic_flag *object); - * - * Initializes 'object'. The initial state is "clear". - * - * void atomic_flag_destroy(volatile atomic_flag *object); - * - * Destroys 'object'. + * An atomic_flag may also be initialized at runtime with atomic_flag_clear(). * * * Operations @@ -336,13 +315,6 @@ ovs_refcount_init(struct ovs_refcount *refcount) atomic_init(&refcount->count, 1); } -/* Destroys 'refcount'. */ -static inline void -ovs_refcount_destroy(struct ovs_refcount *refcount) -{ - atomic_destroy(&refcount->count); -} - /* Increments 'refcount'. */ static inline void ovs_refcount_ref(struct ovs_refcount *refcount)