Add "do { } while (0)" to macros used to remove logging calls, to
ensure there's no code structure change when enabling/disabling
logging.

Signed-off-by: Andre Muezerie <andre...@linux.microsoft.com>
---
 lib/rcu/rte_rcu_qsbr.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/rcu/rte_rcu_qsbr.h b/lib/rcu/rte_rcu_qsbr.h
index 550fadf56a..040bb273e9 100644
--- a/lib/rcu/rte_rcu_qsbr.h
+++ b/lib/rcu/rte_rcu_qsbr.h
@@ -52,7 +52,7 @@ extern int rte_rcu_log_type;
                RTE_LOG_LINE_PREFIX(level, RCU, "%s(): ", __func__, 
__VA_ARGS__); \
 } while (0)
 #else
-#define __RTE_RCU_IS_LOCK_CNT_ZERO(v, thread_id, level, ...)
+#define __RTE_RCU_IS_LOCK_CNT_ZERO(v, thread_id, level, ...) do { } while (0)
 #endif
 
 /* Registered thread IDs are stored as a bitmap of 64b element array.
-- 
2.47.0.vfs.0.3

Reply via email to