lkml.org 
[lkml]   [2013]   [Jan]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH tip/core/rcu 1/1] Tiny RCU changes for 3.9
On Mon, Jan 07, 2013 at 09:56:06AM -0800, Josh Triplett wrote:
> On Mon, Jan 07, 2013 at 08:57:48AM -0800, Paul E. McKenney wrote:
> > On Mon, Jan 07, 2013 at 07:58:10AM -0800, Josh Triplett wrote:
> > > On Sat, Jan 05, 2013 at 09:50:59AM -0800, Paul E. McKenney wrote:
> > > > rcu: Provide RCU CPU stall warnings for tiny RCU
> > > >
> > > > Tiny RCU has historically omitted RCU CPU stall warnings in order to
> > > > reduce memory requirements, however, lack of these warnings caused Thomas
> > > > Gleixner some debugging pain recently. Therefore, this commit adds RCU
> > > > CPU stall warnings to tiny RCU if RCU_TRACE=y. This keeps the memory
> > > > footprint small, while still enabling CPU stall warnings in kernels
> > > > built to enable them.
> > > >
> > > > This is still a bit on the high-risk side, so running this will likely
> > > > be a debugging exercise.
> > > >
> > > > Reported-by: Thomas Gleixner <tglx@linutronix.de>
> > > > Signed-off-by: Paul E. McKenney <paul.mckenney@linaro.org>
> > > > Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
> > >
> > > Did you generate this patch with something other than git? The
> > > formatting seems a bit off: it doesn't have a diffstat or the usual
> > > "---" line between the commit message and the patch.
> >
> > Indeed I did -- couldn't see the point of sending a 0/1 and 1/1
> > series of patches. ;-)
>
> Just don't pass --cover-letter to git format-patch and you won't get the
> 0/1.

Ah, good point! Thank you!

> > > This patch seems reasonable to me, but the repeated use of #if
> > > defined(CONFIG_SMP) || defined(CONFIG_RCU_TRACE) seems somewhat
> > > annoying, and fragile if you ever decide to change the conditions. How
> > > about defining an appropriate symbol in Kconfig for stall warnings, and
> > > using that?
> >
> > But I only just removed the config option for SMP RCU stall warnings. ;-)
> >
> > But I must agree that "defined(CONFIG_SMP) || defined(CONFIG_RCU_TRACE)"
> > is a bit obscure. The rationale is that RCU stall warnings are
> > unconditionally enabled in SMP kernels, but don't want to be in
> > TINY_RCU kernels due to size constraints. I therefore put it under
> > CONFIG_RCU_TRACE, which also contains other TINY_RCU debugging-style
> > options. Would adding a comment to this effect help?
>
> I understand the rationale; I just think it would become clearer if you
> added an internal-only Kconfig symbol selected in both cases and change
> the conditionals to use that.

My concern was that this would confuse people into thinking that the
code under those #ifdefs was all the stall-warning code that there was.

I suppose this could be forestalled with a suitably clever name...
CONFIG_RCU_CPU_STALL_TINY_TOO? Better names?

Thanx, Paul



\
 
 \ /
  Last update: 2013-01-08 00:02    [W:0.062 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site