projects
/
urcu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update version to 0.4.2
[urcu.git]
/
urcu-qsbr-static.h
diff --git
a/urcu-qsbr-static.h
b/urcu-qsbr-static.h
index 2816621f7296d0203e0551d5010d48d9028cfd56..9f3a9b99f3c36ded7961cdeb3eadc102bba0f51d 100644
(file)
--- a/
urcu-qsbr-static.h
+++ b/
urcu-qsbr-static.h
@@
-121,11
+121,6
@@
static inline void debug_yield_init(void)
}
#endif
}
#endif
-static inline void reader_barrier()
-{
- smp_mb();
-}
-
#define RCU_GP_ONLINE (1UL << 0)
#define RCU_GP_CTR (1UL << 1)
#define RCU_GP_ONLINE (1UL << 0)
#define RCU_GP_CTR (1UL << 1)
@@
-161,24
+156,20
@@
static inline void wake_up_gp(void)
}
#if (BITS_PER_LONG < 64)
}
#if (BITS_PER_LONG < 64)
-static inline int rcu_gp_ongoing(unsigned long *
value
)
+static inline int rcu_gp_ongoing(unsigned long *
ctr
)
{
{
- unsigned long
reader_gp
;
+ unsigned long
v
;
- if (value == NULL)
- return 0;
- reader_gp = LOAD_SHARED(*value);
- return reader_gp && ((reader_gp ^ rcu_gp_ctr) & RCU_GP_CTR);
+ v = LOAD_SHARED(*ctr);
+ return v && ((v ^ rcu_gp_ctr) & RCU_GP_CTR);
}
#else /* !(BITS_PER_LONG < 64) */
}
#else /* !(BITS_PER_LONG < 64) */
-static inline int rcu_gp_ongoing(unsigned long *
value
)
+static inline int rcu_gp_ongoing(unsigned long *
ctr
)
{
{
- unsigned long
reader_gp
;
+ unsigned long
v
;
- if (value == NULL)
- return 0;
- reader_gp = LOAD_SHARED(*value);
- return reader_gp && (reader_gp - rcu_gp_ctr > ULONG_MAX / 2);
+ v = LOAD_SHARED(*ctr);
+ return v && (v - rcu_gp_ctr > ULONG_MAX / 2);
}
#endif /* !(BITS_PER_LONG < 64) */
}
#endif /* !(BITS_PER_LONG < 64) */
This page took
0.024276 seconds
and
4
git commands to generate.