[4/5] ring: use rte atomic thread fence

Message ID 1698894265-22963-5-git-send-email-roretzla@linux.microsoft.com (mailing list archive)
State Superseded
Delegated to: David Marchand
Headers
Series use rte atomic thread fence |

Checks

Context Check Description
ci/checkpatch warning coding style issues

Commit Message

Tyler Retzlaff Nov. 2, 2023, 3:04 a.m. UTC
  Use __rte_atomic_thread_fence instead of directly using
__atomic_thread_fence builtin gcc intrinsic

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/ring/rte_ring_c11_pvt.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
  

Patch

diff --git a/lib/ring/rte_ring_c11_pvt.h b/lib/ring/rte_ring_c11_pvt.h
index 5c10ad8..38a003d 100644
--- a/lib/ring/rte_ring_c11_pvt.h
+++ b/lib/ring/rte_ring_c11_pvt.h
@@ -68,7 +68,7 @@ 
 		n = max;
 
 		/* Ensure the head is read before tail */
-		__atomic_thread_fence(rte_memory_order_acquire);
+		__rte_atomic_thread_fence(rte_memory_order_acquire);
 
 		/* load-acquire synchronize with store-release of ht->tail
 		 * in update_tail.
@@ -145,7 +145,7 @@ 
 		n = max;
 
 		/* Ensure the head is read before tail */
-		__atomic_thread_fence(rte_memory_order_acquire);
+		__rte_atomic_thread_fence(rte_memory_order_acquire);
 
 		/* this load-acquire synchronize with store-release of ht->tail
 		 * in update_tail.