From 408f6d9220576478e5ce9a20256d579fc9bfa954 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Tue, 9 Aug 2011 16:42:53 -0400 Subject: [PATCH] urcu-qsbr: move private definitions to .c file The reader does not and should not know about RCU_QS_ACTIVE_ATTEMPTS. Move the definition to urcu-qsbr.c. Also remove KICK_READER_LOOPS. Signed-off-by: Paolo Bonzini Signed-off-by: Mathieu Desnoyers --- urcu-qsbr.c | 5 +++++ urcu/static/urcu-qsbr.h | 12 ------------ 2 files changed, 5 insertions(+), 12 deletions(-) diff --git a/urcu-qsbr.c b/urcu-qsbr.c index 87cf41d..a239be0 100644 --- a/urcu-qsbr.c +++ b/urcu-qsbr.c @@ -52,6 +52,11 @@ int32_t gp_futex; */ unsigned long rcu_gp_ctr = RCU_GP_ONLINE; +/* + * Active attempts to check for reader Q.S. before calling futex(). + */ +#define RCU_QS_ACTIVE_ATTEMPTS 100 + /* * Written to only by each individual reader. Read by both the reader and the * writers. diff --git a/urcu/static/urcu-qsbr.h b/urcu/static/urcu-qsbr.h index c46a7be..5b7adac 100644 --- a/urcu/static/urcu-qsbr.h +++ b/urcu/static/urcu-qsbr.h @@ -55,18 +55,6 @@ extern "C" { * This is required to permit relinking with newer versions of the library. */ -/* - * If a reader is really non-cooperative and refuses to commit its - * rcu_reader.ctr count to memory (there is no barrier in the reader - * per-se), kick it after a few loops waiting for it. - */ -#define KICK_READER_LOOPS 10000 - -/* - * Active attempts to check for reader Q.S. before calling futex(). - */ -#define RCU_QS_ACTIVE_ATTEMPTS 100 - #ifdef DEBUG_RCU #define rcu_assert(args...) assert(args) #else -- 2.34.1