summaryrefslogtreecommitdiffstats
path: root/module/spl/spl-rwlock.c
diff options
context:
space:
mode:
Diffstat (limited to 'module/spl/spl-rwlock.c')
-rw-r--r--module/spl/spl-rwlock.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/module/spl/spl-rwlock.c b/module/spl/spl-rwlock.c
index 9e96c4f27..d99ef4f92 100644
--- a/module/spl/spl-rwlock.c
+++ b/module/spl/spl-rwlock.c
@@ -35,11 +35,15 @@
#if defined(CONFIG_PREEMPT_RT_FULL)
#include <linux/rtmutex.h>
+#define RT_MUTEX_OWNER_MASKALL 1UL
static int
__rwsem_tryupgrade(struct rw_semaphore *rwsem)
{
- ASSERT(rt_mutex_owner(&rwsem->lock) == current);
+
+ ASSERT((struct task_struct *)
+ ((unsigned long)rwsem->lock.owner & ~RT_MUTEX_OWNER_MASKALL) ==
+ current);
/*
* Under the realtime patch series, rwsem is implemented as a