lkml.org 
[lkml]   [2014]   [May]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: vmstat: On demand vmstat workers V5
On Thu, May 29, 2014 at 11:24:15AM -0500, Christoph Lameter wrote:
> On Thu, 29 May 2014, Frederic Weisbecker wrote:
>
> > > Well yes and I am tying directly into that scheme there in cpu.c to
> > > display the active vmstat threads in sysfs. so its the same.
> >
> > I don't think so. Or is there something in vmstat that cpumask_var_t
> > definition depends upon?
>
> This patch definitely ties the vmstat cpumask into the scheme in cpu.c
>
> > > I would like to have some way to display the activities on cpus in /sysfs
> > > like I have done here with the active vmstat workers.
> > >
> > > What I think we need is display cpumasks for
> > >
> > > 1. Cpus where the tick is currently off
> > > 2. Cpus that have dynticks enabled.
> > > 3. Cpus that are idle
> >
> > You should find all that in /proc/timer_list
>
> True. I could actually drop the vmstat cpumask support.
>
> > Now for CPUs that have full dynticks enabled, we probably need something
> > in sysfs. We could dump the nohz cpumask somewhere. For now you can only grep
> > the dmesg
>
> There is a nohz mode in /proc/timer_list right?
>
> > > 4. Cpus that are used for RCU.
> >
> > So, you mean those that aren't in extended grace period (between rcu_user_enter()/exit
> > or rcu_idle_enter/exit)?
>
> No I mean cpus that have their RCU processing directed to another
> processor.

Ah, that is easier!

In kernel/rcu/tree_plugin.c under #ifdef CONFIG_RCU_NOCB_CPU:

cpumask_var_t get_rcu_nocb_mask(void)
{
return rcu_nocb_mask;
}


In include/linux/rcupdate.h:

#if defined(CONFIG_TINY_RCU) || !defined(CONFIG_RCU_NOCB_CPU)
static inline cpumask_var_t get_rcu_nocb_mask(void)
{
return NULL;
}
#else
cpumask_var_t get_rcu_nocb_mask(void);
#endif


Then display the mask however you prefer. Modifying the mask is a very
bad idea, and will void your warranty, etc., etc.

Thanx, Paul



\
 
 \ /
  Last update: 2014-05-29 19:41    [W:0.047 / U:2.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site