Skip to content

Commit

Permalink
srcu: Remove redundant GP sequence checks in srcu_funnel_gp_start
Browse files Browse the repository at this point in the history
We will perform GP sequence checking at the beginning of srcu_gp_start,
thus making it safe to remove duplicate GP sequence checks prior to
calling srcu_gp_start.

Signed-off-by: Feng Lee <379943137@qq.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Uladzislau Rezki (Sony) <urezki@gmail.com>
  • Loading branch information
Feng Lee authored and Uladzislau Rezki (Sony) committed Dec 14, 2024
1 parent cfb07b0 commit 45c7c67
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion kernel/rcu/srcutree.c
Original file line number Diff line number Diff line change
Expand Up @@ -1077,7 +1077,6 @@ static void srcu_funnel_gp_start(struct srcu_struct *ssp, struct srcu_data *sdp,
/* If grace period not already in progress, start it. */
if (!WARN_ON_ONCE(rcu_seq_done(&sup->srcu_gp_seq, s)) &&
rcu_seq_state(sup->srcu_gp_seq) == SRCU_STATE_IDLE) {
WARN_ON_ONCE(ULONG_CMP_GE(sup->srcu_gp_seq, sup->srcu_gp_seq_needed));
srcu_gp_start(ssp);

// And how can that list_add() in the "else" clause
Expand Down

0 comments on commit 45c7c67

Please sign in to comment.