From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Josh Triplett <josh@joshtriplett.org>
Cc: linux-kernel@vger.kernel.org, mingo@elte.hu,
laijs@cn.fujitsu.com, dipankar@in.ibm.com,
akpm@linux-foundation.org, mathieu.desnoyers@polymtl.ca,
niv@us.ibm.com, tglx@linutronix.de, peterz@infradead.org,
rostedt@goodmis.org, Valdis.Kletnieks@vt.edu,
dhowells@redhat.com, eric.dumazet@gmail.com, darren@dvhart.com,
patches@linaro.org, "Paul E. McKenney" <paul.mckenney@linaro.org>
Subject: Re: [PATCH tip/core/rcu 17/86] rcu: fix boost-tracing bug and update tracing documentation
Date: Mon, 2 May 2011 09:19:37 -0700 [thread overview]
Message-ID: <20110502161937.GC6524@linux.vnet.ibm.com> (raw)
In-Reply-To: <20110502161824.GB6524@linux.vnet.ibm.com>
On Mon, May 02, 2011 at 09:18:24AM -0700, Paul E. McKenney wrote:
> On Mon, May 02, 2011 at 01:33:01AM -0700, Paul E. McKenney wrote:
> > On Sun, May 01, 2011 at 08:43:10AM -0700, Josh Triplett wrote:
> > > The bugfix here should really go in a separate commit from the updated
> > > documentation. Also:
> > >
> > > On Sun, May 01, 2011 at 06:20:57AM -0700, Paul E. McKenney wrote:
> > > > --- a/Documentation/RCU/trace.txt
> > > > +++ b/Documentation/RCU/trace.txt
> > > > @@ -10,34 +10,37 @@ for rcutree and next for rcutiny.
> > > >
> > > > CONFIG_TREE_RCU and CONFIG_TREE_PREEMPT_RCU debugfs Files and Formats
> > > >
> > > > -These implementations of RCU provides five debugfs files under the
> > > > +These implementations of RCU provides seven debugfs files under the
> > >
> > > s/seven/several/, so this doesn't continue to need updates as you add
> > > more tracing? It doesn't seem entirely accurate even now, given that
> > > the set of files available now depends on CONFIG_RCU_BOOST.
> >
> > Good point, will fix.
> >
> > > > top-level directory RCU: rcu/rcudata (which displays fields in struct
> > >
> > > RCU or rcu?
> >
> > Indeed, "rcu". Will fix.
> >
> > > > rcu_data), rcu/rcudata.csv (which is a .csv spreadsheet version of
> > > > rcu/rcudata), rcu/rcugp (which displays grace-period counters),
> > > > -rcu/rcuhier (which displays the struct rcu_node hierarchy), and
> > > > +rcu/rcuhier (which displays the struct rcu_node hierarchy),
> > > > rcu/rcu_pending (which displays counts of the reasons that the
> > > > -rcu_pending() function decided that there was core RCU work to do).
> > > > +rcu_pending() function decided that there was core RCU work to do),
> > > > +rcu/rcutorture (which displays rcutorture test progress), and, if the
> > > > +kernel is built with CONFIG_RCU_BOOST, rcu/rcuboost (which displays RCU
> > > > +boosting statistics).
> > >
> > > I think this would work better as a list:
> > >
> > > rcu/rcudata:
> > > Displays fields in struct rcu_data.
> > > rcu/rcudata.csv:
> > > Comma-separated values spreadsheet version of rcudata.
> > > rcu/rcugp:
> > > Displays grace-period counters.
> > > rcu/rcuhier
> > > Displays the struct rcu_node hierarchy.
> > > rcu/rcu_pending:
> > > Displays counts of the reasons rcu_pending() decided that RCU had
> > > work to do.
> > > rcu/rcutorture:
> > > Displays rcutorture test progress.
> > > rcu/rcuboost
> > > Displays RCU boosting statistics. Only present if
> > > CONFIG_RCU_BOOST=y.
> > >
> > > Feel free to put the descriptions on the same lines as the filenames if
> > > you prefer; however, I thought this style worked better for the
> > > descriptions longer than one line.
> >
> > Makes sense, will do a list.
> >
> > > Also, does rcu/rcutorture appear with rcutorture not loaded? Hopefully
> > > not, since rcutorture shouldn't take up any additional resources when
> > > not loaded.
> >
> > Not much choice, unfortunately. If I put the info into rcutorture, then
> > I lose it when rcutorture is unloaded. This is problematic in automated
> > tests that repeatedly load and unload rcutorture.
> >
> > But the amount of data is small, and I set things up so that TINY_RCU
> > can omit this. TREE_RCU is big enough that it doesn't really matter.
> >
> > > > --- a/kernel/rcutree_plugin.h
> > > > +++ b/kernel/rcutree_plugin.h
> > > > @@ -1086,7 +1086,7 @@ static void rcu_initiate_boost_trace(struct rcu_node *rnp)
> > > > else if (rnp->gp_tasks != NULL && rnp->qsmask != 0)
> > > > rnp->n_balk_notblocked++;
> > > > else if (rnp->gp_tasks != NULL &&
> > > > - ULONG_CMP_GE(jiffies, rnp->boost_time))
> > > > + ULONG_CMP_LT(jiffies, rnp->boost_time))
> > > > rnp->n_balk_notyet++;
> > > > else
> > > > rnp->n_balk_nos++;
> > >
> > > This bugfix should go in a separate commit.
> >
> > Excellent point, will fix.
>
> Here is the updated documentation update.
And here is the bug fix.
Thanx, Paul
------------------------------------------------------------------------
rcu: fix tracing bug thinko on boost-balk attribution
The rcu_initiate_boost_trace() function mis-attributed refusals to
initiate RCU priority boosting that were in fact due to its not yet
being time to boost. This patch fixes the faulty comparison.
Signed-off-by: Paul E. McKenney <paul.mckenney@linaro.org>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h
index 22a6a46..a21413d 100644
--- a/kernel/rcutree_plugin.h
+++ b/kernel/rcutree_plugin.h
@@ -1086,7 +1086,7 @@ static void rcu_initiate_boost_trace(struct rcu_node *rnp)
else if (rnp->gp_tasks != NULL && rnp->qsmask != 0)
rnp->n_balk_notblocked++;
else if (rnp->gp_tasks != NULL &&
- ULONG_CMP_GE(jiffies, rnp->boost_time))
+ ULONG_CMP_LT(jiffies, rnp->boost_time))
rnp->n_balk_notyet++;
else
rnp->n_balk_nos++;
next prev parent reply other threads:[~2011-05-02 21:37 UTC|newest]
Thread overview: 126+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-01 13:21 [PATCH tip/core/rcu 0/6] Preview of RCU patches for 2.6.40 Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 01/86] rcu: Remove conditional compilation for RCU CPU stall warnings Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 02/86] rcu: Decrease memory-barrier usage based on semi-formal proof Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 03/86] rcu: merge TREE_PREEPT_RCU blocked_tasks[] lists Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 04/86] rcu: Update documentation to reflect blocked_tasks[] merge Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 05/86] rcu: move TREE_RCU from softirq to kthread Paul E. McKenney
2011-05-05 9:31 ` Yong Zhang
2011-05-06 5:46 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 06/86] rcu: priority boosting for TREE_PREEMPT_RCU Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 07/86] rcu: Force per-rcu_node kthreads off of the outgoing CPU Paul E. McKenney
2011-05-01 15:10 ` Josh Triplett
2011-05-02 10:25 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 08/86] rcu: put per-CPU kthread at non-RT priority during CPU hotplug operations Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 09/86] rcu: avoid hammering sched with yet another bound RT kthread Paul E. McKenney
2011-05-01 15:48 ` Josh Triplett
2011-05-02 8:23 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 10/86] rcu: eliminate unused boosting statistics Paul E. McKenney
2011-05-01 15:53 ` Josh Triplett
2011-05-02 8:25 ` Paul E. McKenney
2011-05-02 16:15 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 11/86] rcu: Add boosting to TREE_PREEMPT_RCU tracing Paul E. McKenney
2011-05-01 15:52 ` Josh Triplett
2011-05-02 8:27 ` Paul E. McKenney
2011-05-02 17:53 ` Josh Triplett
2011-05-02 22:19 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 12/86] rcu: Update RCU's trace.txt documentation for new format Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 13/86] rcu: add callback-queue information to rcudata output Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 14/86] rcu: document new callback-queue trace information Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 15/86] rcu: add tracing for RCU's kthread run states Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 16/86] rcu: make rcutorture version numbers available through debugfs Paul E. McKenney
2011-05-01 15:29 ` Josh Triplett
2011-05-02 8:30 ` Paul E. McKenney
2011-05-02 17:39 ` Josh Triplett
2011-05-01 13:20 ` [PATCH tip/core/rcu 17/86] rcu: fix boost-tracing bug and update tracing documentation Paul E. McKenney
2011-05-01 15:43 ` Josh Triplett
2011-05-02 8:33 ` Paul E. McKenney
2011-05-02 16:18 ` Paul E. McKenney
2011-05-02 16:19 ` Paul E. McKenney [this message]
2011-05-02 17:44 ` Josh Triplett
2011-05-02 22:19 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 18/86] rcu: add grace-period age to tracing Paul E. McKenney
2011-05-01 15:25 ` Josh Triplett
2011-05-02 8:34 ` Paul E. McKenney
2011-05-02 10:52 ` Paul E. McKenney
2011-05-02 16:21 ` Paul E. McKenney
2011-05-01 13:20 ` [PATCH tip/core/rcu 19/86] rcu: Add forward-progress diagnostic for per-CPU kthreads Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 20/86] rcu: Enable DEBUG_OBJECTS_RCU_HEAD from !PREEMPT Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 21/86] rcu: add DEBUG_OBJECTS_RCU_HEAD check for alignment Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 22/86] rcu: mark rcutorture boosting callback as being on-stack Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 23/86] rcu: Use WARN_ON_ONCE for DEBUG_OBJECTS_RCU_HEAD warnings Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 24/86] rcu: Switch to this_cpu() primitives Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 25/86] rcu: code cleanups in TINY_RCU priority boosting Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 26/86] rcu: remove useless ->boosted_this_gp field Paul E. McKenney
2011-05-01 16:05 ` Josh Triplett
2011-05-02 8:34 ` Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 27/86] rcu: Converge TINY_RCU expedited and normal boosting Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 28/86] rcu: call __rcu_read_unlock() in exit_rcu for tree RCU Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 29/86] rcu: fix spelling Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 30/86] rcu: introduce kfree_rcu() Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 31/86] rcu: further lower priority in rcu_yield() Paul E. McKenney
2011-05-01 17:51 ` Mike Galbraith
2011-05-02 8:11 ` Paul E. McKenney
2011-05-02 9:33 ` Mike Galbraith
2011-05-01 13:21 ` [PATCH tip/core/rcu 32/86] rcu: prevent call_rcu() from diving into rcu core if irqs disabled Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 33/86] rcu: optimize rcutiny Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 34/86] cgroup,rcu: convert call_rcu(free_css_set_rcu) to kfree_rcu() Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 35/86] cgroup,rcu: convert call_rcu(free_cgroup_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 36/86] cgroup,rcu: convert call_rcu(__free_css_id_cb) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 37/86] net,rcu: convert call_rcu(tcf_common_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 38/86] net,rcu: convert call_rcu(tcf_police_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 39/86] net,rcu: convert call_rcu(in6_dev_finish_destroy_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 40/86] net,rcu: convert call_rcu(inet6_ifa_finish_destroy_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 41/86] net,rcu: convert call_rcu(listeners_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 42/86] net,rcu: convert call_rcu(sctp_local_addr_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 43/86] net,rcu: convert call_rcu(ha_rcu_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 44/86] net,rcu: convert call_rcu(dn_dev_free_ifa_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 45/86] net,act_police,rcu: remove rcu_barrier() Paul E. McKenney
2011-05-01 15:59 ` Josh Triplett
2011-05-02 8:36 ` Paul E. McKenney
2011-05-02 17:50 ` Josh Triplett
2011-05-02 22:21 ` Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 46/86] security,rcu: convert call_rcu(user_update_rcu_disposal) to kfree_rcu() Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 47/86] net,rcu: convert call_rcu(fc_rport_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 48/86] net,rcu: convert call_rcu(__leaf_info_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 49/86] net,rcu: convert call_rcu(__gen_kill_estimator) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 50/86] net,rcu: convert call_rcu(ip_mc_list_reclaim) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 51/86] net,rcu: convert call_rcu(ip_sf_socklist_reclaim) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 52/86] net,rcu: convert call_rcu(ip_mc_socklist_reclaim) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 53/86] net,rcu: convert call_rcu(free_dm_hw_stat) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 54/86] ixgbe,rcu: convert call_rcu(ring_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 55/86] macvlan,rcu: convert call_rcu(macvlan_port_rcu_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 56/86] net,rcu: convert call_rcu(ipv6_mc_socklist_reclaim) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 57/86] net,rcu: convert call_rcu(rps_map_release) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 58/86] net,rcu: convert call_rcu(xps_map_release) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 59/86] net,rcu: convert call_rcu(xps_dev_maps_release) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 60/86] security,rcu: convert call_rcu(sel_netif_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 61/86] net,rcu: convert call_rcu(netlbl_unlhsh_free_addr4) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 62/86] net,rcu: convert call_rcu(netlbl_unlhsh_free_addr6) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 63/86] net,rcu: convert call_rcu(net_generic_release) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 64/86] net,rcu: convert call_rcu(__nf_ct_ext_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 65/86] perf,rcu: convert call_rcu(free_ctx) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 66/86] perf,rcu: convert call_rcu(swevent_hlist_release_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 67/86] net,rcu: convert call_rcu(phonet_device_rcu_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 68/86] net,rcu: convert call_rcu(wq_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 69/86] net/mac80211,rcu: convert call_rcu(work_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 70/86] net,rcu: convert call_rcu(xt_osf_finger_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 71/86] net,rcu: convert call_rcu(kfree_tid_tx) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 72/86] audit_tree,rcu: convert call_rcu(__put_tree) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 73/86] block,rcu: convert call_rcu(cfq_cfqd_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 74/86] nfs,rcu: convert call_rcu(nfs_free_delegation_callback) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 75/86] security,rcu: convert call_rcu(whitelist_item_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 76/86] scsi,rcu: convert call_rcu(fc_rport_free_rcu) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 77/86] block,rcu: convert call_rcu(disk_free_ptbl_rcu_cb) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 78/86] ia64,rcu: convert call_rcu(sn_irq_info_free) " Paul E. McKenney
2011-05-01 13:21 ` [PATCH tip/core/rcu 79/86] jbd2,rcu: convert call_rcu(free_devcache) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 80/86] md,rcu: convert call_rcu(free_conf) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 81/86] security,rcu: convert call_rcu(sel_netnode_free) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 82/86] security,rcu: convert call_rcu(sel_netport_free) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 83/86] ipc,rcu: convert call_rcu(free_un) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 84/86] ipc,rcu: convert call_rcu(ipc_immediate_free) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 85/86] vmalloc,rcu: convert call_rcu(rcu_free_va) " Paul E. McKenney
2011-05-01 13:22 ` [PATCH tip/core/rcu 86/86] vmalloc,rcu: convert call_rcu(rcu_free_vb) " Paul E. McKenney
2011-05-01 16:14 ` [PATCH tip/core/rcu 0/6] Preview of RCU patches for 2.6.40 Josh Triplett
2011-05-02 8:37 ` Paul E. McKenney
2011-05-01 23:49 ` Dave Chinner
2011-05-02 8:09 ` 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=20110502161937.GC6524@linux.vnet.ibm.com \
--to=paulmck@linux.vnet.ibm.com \
--cc=Valdis.Kletnieks@vt.edu \
--cc=akpm@linux-foundation.org \
--cc=darren@dvhart.com \
--cc=dhowells@redhat.com \
--cc=dipankar@in.ibm.com \
--cc=eric.dumazet@gmail.com \
--cc=josh@joshtriplett.org \
--cc=laijs@cn.fujitsu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mathieu.desnoyers@polymtl.ca \
--cc=mingo@elte.hu \
--cc=niv@us.ibm.com \
--cc=patches@linaro.org \
--cc=paul.mckenney@linaro.org \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.