diff options
author | Davidlohr Bueso <dave@stgolabs.net> | 2020-01-07 17:33:04 -0800 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2020-02-11 13:11:02 +0100 |
commit | 41f0e29190ac9e38099a37abd1a8a4cb1dc21233 (patch) | |
tree | 6be0cb6216fc9925a68630c95389641d3db778ed /kernel/locking/percpu-rwsem.c | |
parent | ac8dec420970f5cbaf2f6eda39153a60ec5b257b (diff) |
locking/percpu-rwsem: Add might_sleep() for writer locking
We are missing this annotation in percpu_down_write(). Correct
this.
Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Acked-by: Will Deacon <will@kernel.org>
Acked-by: Waiman Long <longman@redhat.com>
Link: https://lkml.kernel.org/r/20200108013305.7732-1-dave@stgolabs.net
Diffstat (limited to 'kernel/locking/percpu-rwsem.c')
-rw-r--r-- | kernel/locking/percpu-rwsem.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/locking/percpu-rwsem.c b/kernel/locking/percpu-rwsem.c index 8048a9a255d5..183a3aaa8509 100644 --- a/kernel/locking/percpu-rwsem.c +++ b/kernel/locking/percpu-rwsem.c @@ -212,6 +212,7 @@ static bool readers_active_check(struct percpu_rw_semaphore *sem) void percpu_down_write(struct percpu_rw_semaphore *sem) { + might_sleep(); rwsem_acquire(&sem->dep_map, 0, 0, _RET_IP_); /* Notify readers to take the slow path. */ |