From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Neeraj Upadhyay <neeraju@codeaurora.org>
Cc: josh@joshtriplett.org, rostedt@goodmis.org,
mathieu.desnoyers@efficios.com, jiangshanlai@gmail.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] rcu: Skip additional checks if rcu_cpu_stall_suppress is set
Date: Tue, 8 Aug 2017 11:02:08 -0700 [thread overview]
Message-ID: <20170808180208.GF3730@linux.vnet.ibm.com> (raw)
In-Reply-To: <1502212826-18846-1-git-send-email-neeraju@codeaurora.org>
On Tue, Aug 08, 2017 at 10:50:26PM +0530, Neeraj Upadhyay wrote:
> If rcu_kick_kthreads is set, and gp is in progress, check_cpu_stall()
> does checks to figure out whether jiffies is past rsp->jiffies_stall,
> doing ordered accesses to avoid any false positives for new grace
> period initialization after a sufficiently large idle period. This
> extra processing can be skipped if rcu_cpu_stall_suppress is set.
Just to make sure I understand, the concern is that someone might have
booted with rcupdate.rcu_cpu_stall_suppress=1 (thus suppressing the RCU
CPU stall debugging warnings implemented later in check_cpu_stall()),
but later decided to also boot with rcutree.rcu_kick_kthreads=1 (thus
enabling kicking kthreads which check for RCU's grace-period kthreads
not being properly awakened)?
My immediate reaction is that if there is not much point in specifying
both rcutree.rcu_kick_kthreads=1 and rcupdate.rcu_cpu_stall_suppress=1.
But is there some use case that I am missing?
Thanx, Paul
> Fixes: 8c7c4829a81c ("rcu: Awaken grace-period kthread if too long since FQS")
> Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
> ---
> kernel/rcu/tree.c | 7 +++++--
> 1 file changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
> index 51d4c3a..91b7552 100644
> --- a/kernel/rcu/tree.c
> +++ b/kernel/rcu/tree.c
> @@ -1562,10 +1562,13 @@ static void check_cpu_stall(struct rcu_state *rsp, struct rcu_data *rdp)
> unsigned long js;
> struct rcu_node *rnp;
>
> - if ((rcu_cpu_stall_suppress && !rcu_kick_kthreads) ||
> - !rcu_gp_in_progress(rsp))
> + if (!rcu_gp_in_progress(rsp))
> return;
> rcu_stall_kick_kthreads(rsp);
> +
> + if (rcu_cpu_stall_suppress)
> + return;
> +
> j = jiffies;
>
> /*
> --
> QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a
> member of the Code Aurora Forum, hosted by The Linux Foundation
>
next prev parent reply other threads:[~2017-08-08 18:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-08 17:20 [PATCH] rcu: Skip additional checks if rcu_cpu_stall_suppress is set Neeraj Upadhyay
2017-08-08 18:02 ` Paul E. McKenney [this message]
2017-08-08 18:57 ` Neeraj Upadhyay
2017-08-08 21:56 ` Paul E. McKenney
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170808180208.GF3730@linux.vnet.ibm.com \
--to=paulmck@linux.vnet.ibm.com \
--cc=jiangshanlai@gmail.com \
--cc=josh@joshtriplett.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mathieu.desnoyers@efficios.com \
--cc=neeraju@codeaurora.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox