Skip to content

Commit

Permalink
[PATCH] Fix bug in RCU torture test
Browse files Browse the repository at this point in the history
While doing some test of RCU torture module, I hit a OOPS in rcu_do_batch,
which was trying to processes callback of a module that was just removed.
This is because we weren't waiting long enough for all callbacks to fire.

Signed-off-by: Srivatsa Vaddagiri <vatsa@in.ibm.com>
Cc: Dipankar Sarma <dipankar@in.ibm.com>
Acked-by: "Paul E. McKenney" <paulmck@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Srivatsa Vaddagiri authored and Linus Torvalds committed Dec 12, 2005
1 parent ab4720e commit 89d46b8
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions kernel/rcutorture.c
Original file line number Diff line number Diff line change
Expand Up @@ -409,9 +409,8 @@ rcu_torture_cleanup(void)
stats_task = NULL;

/* Wait for all RCU callbacks to fire. */
rcu_barrier();

for (i = 0; i < RCU_TORTURE_PIPE_LEN; i++)
synchronize_rcu();
rcu_torture_stats_print(); /* -After- the stats thread is stopped! */
printk(KERN_ALERT TORTURE_FLAG
"--- End of test: %s\n",
Expand Down

0 comments on commit 89d46b8

Please sign in to comment.