projects
/
urcu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add multiflavor test program
[urcu.git]
/
tests
/
test_urcu_wfq.c
diff --git
a/tests/test_urcu_wfq.c
b/tests/test_urcu_wfq.c
index 75a9275e74f2d9a4ae42c2fd1e9fa4ce33751546..d1760414f30378151a62d8c34656e9f09002d6fc 100644
(file)
--- a/
tests/test_urcu_wfq.c
+++ b/
tests/test_urcu_wfq.c
@@
-65,6
+65,10
@@
static inline pid_t gettid(void)
#ifndef DYNAMIC_LINK_TEST
#define _LGPL_SOURCE
#endif
#ifndef DYNAMIC_LINK_TEST
#define _LGPL_SOURCE
#endif
+
+/* Remove deprecation warnings from test build. */
+#define CDS_WFQ_DEPRECATED
+
#include <urcu.h>
#include <urcu/wfqueue.h>
#include <urcu.h>
#include <urcu/wfqueue.h>
@@
-77,9
+81,9
@@
static unsigned long duration;
/* read-side C.S. duration, in loops */
static unsigned long wdelay;
/* read-side C.S. duration, in loops */
static unsigned long wdelay;
-static inline void loop_sleep(unsigned long l)
+static inline void loop_sleep(unsigned long l
oops
)
{
{
- while
(l
-- != 0)
+ while
(loops
-- != 0)
caa_cpu_relax();
}
caa_cpu_relax();
}
@@
-105,9
+109,10
@@
typedef unsigned long cpu_set_t;
static void set_affinity(void)
{
static void set_affinity(void)
{
+#if HAVE_SCHED_SETAFFINITY
cpu_set_t mask;
cpu_set_t mask;
- int cpu;
- int ret;
+ int cpu
, ret
;
+#endif /* HAVE_SCHED_SETAFFINITY */
if (!use_affinity)
return;
if (!use_affinity)
return;
This page took
0.024635 seconds
and
4
git commands to generate.