projects
/
linux-2.6-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5f35d5a
)
locking/mutex: Use mutex flags macro instead of hard code
author
Mukesh Ojha
<mojha@codeaurora.org>
Wed, 31 Jul 2019 15:05:04 +0000
(20:35 +0530)
committer
Peter Zijlstra
<peterz@infradead.org>
Tue, 6 Aug 2019 10:49:16 +0000
(12:49 +0200)
Use the mutex flag macro instead of hard code value inside
__mutex_owner().
Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: mingo@redhat.com
Cc: will@kernel.org
Link:
https://lkml.kernel.org/r/1564585504-3543-2-git-send-email-mojha@codeaurora.org
kernel/locking/mutex.c
patch
|
blob
|
blame
|
history
diff --git
a/kernel/locking/mutex.c
b/kernel/locking/mutex.c
index ac4929f1e085e7dd4fcb4bc455a7b936b4420289..b4bcb0236d7a15297d425648fdbf598bf8ffc684 100644
(file)
--- a/
kernel/locking/mutex.c
+++ b/
kernel/locking/mutex.c
@@
-85,7
+85,7
@@
EXPORT_SYMBOL(__mutex_init);
*/
static inline struct task_struct *__mutex_owner(struct mutex *lock)
{
- return (struct task_struct *)(atomic_long_read(&lock->owner) & ~
0x07
);
+ return (struct task_struct *)(atomic_long_read(&lock->owner) & ~
MUTEX_FLAGS
);
}
static inline struct task_struct *__owner_task(unsigned long owner)