summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Hellstrom <thellstrom@vmware.com>2018-06-14 08:45:29 +0200
committerThomas Hellstrom <thellstrom@vmware.com>2018-06-14 08:45:29 +0200
commit087cd8e356129c9b53c2ce29c71817aa386fb027 (patch)
tree21db3eafe90792f5840dcecded55ea28cceb41a9
parent42e739628260961ecd7fa38025da066db1ebebbb (diff)
Adapt to new API.patch-18-06-14
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
-rw-r--r--ww_mutex_test.c6
-rw-r--r--ww_mutex_test.h2
2 files changed, 6 insertions, 2 deletions
diff --git a/ww_mutex_test.c b/ww_mutex_test.c
index 3276521..ec7408a 100644
--- a/ww_mutex_test.c
+++ b/ww_mutex_test.c
@@ -52,7 +52,11 @@ struct wwt_thread {
static struct wwt_device g_dev;
static struct wwt_thread threads[WWT_NUM_THREADS];
-static DEFINE_WW_CLASS(wwt_class, WW_WAITDIE);
+#ifdef WW_WAITDIE
+static DEFINE_WW_CLASS_WDIE(wwt_class);
+#else
+static DEFINE_WW_CLASS(wwt_class);
+#endif
static void wwt_thread_rollback(struct wwt_thread *t, int upto)
{
diff --git a/ww_mutex_test.h b/ww_mutex_test.h
index 80b63ba..5356562 100644
--- a/ww_mutex_test.h
+++ b/ww_mutex_test.h
@@ -7,7 +7,7 @@
#define _WW_MUTEX_TEST_H_
#define WW_BUILTIN /* Use kernel builtin ww mutexes */
-#define WW_WAITDIE false /* Use wait-die, not wound-wait */
+#undef WW_WAITDIE /* Use wait-die, not wound-wait */
#define WW_BATCHING /* Batch locks and unlocks */
#define WWT_NUM_LOCKS 100000 /* Number of global locks */
#define WWT_NUM_T_LOCKS 800 /* Number of locks per thread out of the global */