From 6e8b8429a09800f5a50f0410f5ec4cd95b46974b Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Mon, 9 Feb 2009 13:00:31 -0500 Subject: [PATCH] Fix data type, should now be long rather than int. Signed-off-by: Mathieu Desnoyers --- urcu.c | 4 ++-- urcu.h | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/urcu.c b/urcu.c index 5514b27..53c7f37 100644 --- a/urcu.c +++ b/urcu.c @@ -20,9 +20,9 @@ pthread_mutex_t urcu_mutex = PTHREAD_MUTEX_INITIALIZER; /* Global grace period counter */ -int urcu_gp_ctr; +long urcu_gp_ctr; -int __thread urcu_active_readers; +long __thread urcu_active_readers; /* Thread IDs of registered readers */ #define INIT_NUM_THREADS 4 diff --git a/urcu.h b/urcu.h index b8f6d9b..4249806 100644 --- a/urcu.h +++ b/urcu.h @@ -175,13 +175,13 @@ static inline void debug_yield_init(void) * Using a int rather than a char to eliminate false register dependencies * causing stalls on some architectures. */ -extern int urcu_gp_ctr; +extern long urcu_gp_ctr; -extern int __thread urcu_active_readers; +extern long __thread urcu_active_readers; static inline int rcu_old_gp_ongoing(int *value) { - int v; + long v; if (value == NULL) return 0; @@ -194,7 +194,7 @@ static inline int rcu_old_gp_ongoing(int *value) static inline void rcu_read_lock(void) { - int tmp; + long tmp; debug_yield_read(); tmp = urcu_active_readers; -- 2.34.1