Skip to content

Commit c93ffc1

Browse files
author
Paul E. McKenney
committed
fs/file: Replace synchronize_sched() with synchronize_rcu()
Now that synchronize_rcu() waits for preempt-disable regions of code as well as RCU read-side critical sections, synchronize_sched() can be replaced by synchronize_rcu(). This commit therefore makes this change. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: <linux-fsdevel@vger.kernel.org>
1 parent cc69b38 commit c93ffc1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/file.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ static int expand_fdtable(struct files_struct *files, unsigned int nr)
158158
* or have finished their rcu_read_lock_sched() section.
159159
*/
160160
if (atomic_read(&files->count) > 1)
161-
synchronize_sched();
161+
synchronize_rcu();
162162

163163
spin_lock(&files->file_lock);
164164
if (!new_fdt)

0 commit comments

Comments
 (0)