aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/rcu/srcutiny.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/rcu/srcutiny.c')
-rw-r--r--kernel/rcu/srcutiny.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/rcu/srcutiny.c b/kernel/rcu/srcutiny.c
index 622792abe41a..04fc2ed71af8 100644
--- a/kernel/rcu/srcutiny.c
+++ b/kernel/rcu/srcutiny.c
@@ -110,7 +110,7 @@ void __srcu_read_unlock(struct srcu_struct *sp, int idx)
110 110
111 WRITE_ONCE(sp->srcu_lock_nesting[idx], newval); 111 WRITE_ONCE(sp->srcu_lock_nesting[idx], newval);
112 if (!newval && READ_ONCE(sp->srcu_gp_waiting)) 112 if (!newval && READ_ONCE(sp->srcu_gp_waiting))
113 swake_up(&sp->srcu_wq); 113 swake_up_one(&sp->srcu_wq);
114} 114}
115EXPORT_SYMBOL_GPL(__srcu_read_unlock); 115EXPORT_SYMBOL_GPL(__srcu_read_unlock);
116 116
@@ -140,7 +140,7 @@ void srcu_drive_gp(struct work_struct *wp)
140 idx = sp->srcu_idx; 140 idx = sp->srcu_idx;
141 WRITE_ONCE(sp->srcu_idx, !sp->srcu_idx); 141 WRITE_ONCE(sp->srcu_idx, !sp->srcu_idx);
142 WRITE_ONCE(sp->srcu_gp_waiting, true); /* srcu_read_unlock() wakes! */ 142 WRITE_ONCE(sp->srcu_gp_waiting, true); /* srcu_read_unlock() wakes! */
143 swait_event(sp->srcu_wq, !READ_ONCE(sp->srcu_lock_nesting[idx])); 143 swait_event_exclusive(sp->srcu_wq, !READ_ONCE(sp->srcu_lock_nesting[idx]));
144 WRITE_ONCE(sp->srcu_gp_waiting, false); /* srcu_read_unlock() cheap. */ 144 WRITE_ONCE(sp->srcu_gp_waiting, false); /* srcu_read_unlock() cheap. */
145 145
146 /* Invoke the callbacks we removed above. */ 146 /* Invoke the callbacks we removed above. */