[PATCH v2 12/13] rcutorture: Announce declining to forward-progress test
"Paul E. McKenney" <[email protected]> Thu, 30 Jul 2026 18:07:18 -0700
| Newsgroups | org.kernel.vger.rcu,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
Currently, rcu_torture_fwd_prog_cr() announces function entry, but silently exits if rcu_fwd_emergency_stop is set or if there is no ->call() function available. This could cause confusion, leading people to believe that rcu_torture_fwd_prog_cr() is on the job when it is not. This commit therefore also announces the early exits from this function. Signed-off-by: Paul E. McKenney <[email protected]> --- kernel/rcu/rcutorture.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/kernel/rcu/rcutorture.c b/kernel/rcu/rcutorture.c index 9180016d87c0ce..46d97055c2fcde 100644 --- a/kernel/rcu/rcutorture.c +++ b/kernel/rcu/rcutorture.c @@ -3623,13 +3623,17 @@ static void rcu_torture_fwd_prog_cr(struct rcu_fwd *rfp) unsigned long stopat; unsigned long stoppedat; - pr_alert("%s: Starting forward-progress test %d\n", __func__, rfp->rcu_fwd_id); - if (READ_ONCE(rcu_fwd_emergency_stop)) + if (READ_ONCE(rcu_fwd_emergency_stop)) { + pr_alert("%s: Emergency stop, so no forward-progress test %d\n", __func__, rfp->rcu_fwd_id); return; /* Get out of the way quickly, no GP wait! */ - if (!cur_ops->call) + } + if (!cur_ops->call) { + pr_alert("%s: No ->call(), so no forward-progress test %d\n", __func__, rfp->rcu_fwd_id); return; /* Can't do call_rcu() fwd prog without ->call. */ + } /* Loop continuously posting RCU callbacks. */ + pr_alert("%s: Starting forward-progress test %d\n", __func__, rfp->rcu_fwd_id); atomic_inc(&rcu_fwd_cb_nodelay); cur_ops->sync(); /* Later readers see above write. */ WRITE_ONCE(rfp->rcu_fwd_startat, jiffies); -- 2.40.1