linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
To: Dave Hansen <dave@linux.vnet.ibm.com>
Cc: kosaki.motohiro@jp.fujitsu.com, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org, lnxninja@linux.vnet.ibm.com,
	kamezawa.hiroyu@jp.fujitsu.com, ebiederm@xmission.com
Subject: Re: [RFCv2][PATCH] add some drop_caches documentation and info messsge
Date: Tue, 21 Sep 2010 09:57:31 +0900 (JST)	[thread overview]
Message-ID: <20100921094658.3BE3.A69D9226@jp.fujitsu.com> (raw)
In-Reply-To: <1284738841.25231.4387.camel@nimitz>

> On Fri, 2010-09-17 at 09:26 +0900, KOSAKI Motohiro wrote:
> > > diff -puN fs/drop_caches.c~update-drop_caches-documentation fs/drop_caches.c
> > > --- linux-2.6.git/fs/drop_caches.c~update-drop_caches-documentation	2010-09-16 09:43:52.000000000 -0700
> > > +++ linux-2.6.git-dave/fs/drop_caches.c	2010-09-16 09:43:52.000000000 -0700
> > > @@ -47,6 +47,8 @@ int drop_caches_sysctl_handler(ctl_table
> > >  {
> > >  	proc_dointvec_minmax(table, write, buffer, length, ppos);
> > >  	if (write) {
> > > +		printk(KERN_NOTICE "%s (%d): dropped kernel caches: %d\n",
> > > +			current->comm, task_pid_nr(current), sysctl_drop_caches);
> > >  		if (sysctl_drop_caches & 1)
> > >  			iterate_supers(drop_pagecache_sb, NULL);
> > >  		if (sysctl_drop_caches & 2)
> > 
> > Can't you print it only once?
> 
> Sure.  But, I also figured that somebody calling it every minute is
> going to be much more interesting than something just on startup.
> Should we printk_ratelimit() it, perhaps?

Umm...

every minute drop_caches + printk_ratelimit() mean every drop_caches output
printk(). It seems annoying. I'm worry about that I'll see drop_caches's printk fill
my syslog.

But, It is not strong opinion. Because I don't use every minute drop_caches, then
I have no experience such usecase. It's up to you.



--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2010-09-21  0:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-16 16:50 Dave Hansen
2010-09-17  0:26 ` KOSAKI Motohiro
2010-09-17 15:54   ` Dave Hansen
2010-09-21  0:57     ` KOSAKI Motohiro [this message]
2010-09-21  1:00 ` KAMEZAWA Hiroyuki

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=20100921094658.3BE3.A69D9226@jp.fujitsu.com \
    --to=kosaki.motohiro@jp.fujitsu.com \
    --cc=dave@linux.vnet.ibm.com \
    --cc=ebiederm@xmission.com \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=lnxninja@linux.vnet.ibm.com \
    /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