lkml.org 
[lkml]   [2020]   [Jan]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] locking/percpu-rwsem: Add might_sleep() for writer locking
Date
We are missing this annotation in percpu_down_write(). Correct
this.

Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
---

Applies against your queue tree.

kernel/locking/percpu-rwsem.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/kernel/locking/percpu-rwsem.c b/kernel/locking/percpu-rwsem.c
index 4cbeeada8d09..08db2abfa00d 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. */
--
2.16.4
\
 
 \ /
  Last update: 2020-01-08 02:40    [W:0.042 / U:0.472 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site