[PATCH] locking/percpu-rwsem: Remove WQ_FLAG_EXCLUSIVE flags

From: qiang.zhang
Date: Thu Jul 02 2020 - 03:44:13 EST


From: Zqiang <qiang.zhang@xxxxxxxxxxxxx>

Remove WQ_FLAG_EXCLUSIVE from "wq_entry.flags", using function
__add_wait_queue_entry_tail_exclusive substitution.

Signed-off-by: Zqiang <qiang.zhang@xxxxxxxxxxxxx>
---
kernel/locking/percpu-rwsem.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/kernel/locking/percpu-rwsem.c b/kernel/locking/percpu-rwsem.c
index 8bbafe3e5203..48e1c55c2e59 100644
--- a/kernel/locking/percpu-rwsem.c
+++ b/kernel/locking/percpu-rwsem.c
@@ -148,8 +148,8 @@ static void percpu_rwsem_wait(struct percpu_rw_semaphore *sem, bool reader)
*/
wait = !__percpu_rwsem_trylock(sem, reader);
if (wait) {
- wq_entry.flags |= WQ_FLAG_EXCLUSIVE | reader * WQ_FLAG_CUSTOM;
- __add_wait_queue_entry_tail(&sem->waiters, &wq_entry);
+ wq_entry.flags |= reader * WQ_FLAG_CUSTOM;
+ __add_wait_queue_entry_tail_exclusive(&sem->waiters, &wq_entry);
}
spin_unlock_irq(&sem->waiters.lock);

--
2.24.1