Re: [patch] drop_caches: add some documentation and info message

2014-02-11 Thread Andrew Morton
On Mon, 10 Feb 2014 16:54:16 -0500 Johannes Weiner wrote: > How about this: we allow disabling the log message, but print the line > of the disabling call so it's clear who dunnit. To make sure valuable > info is not missing in bug reports, add counters for the two events in > /proc/vmstat. >

Re: [patch] drop_caches: add some documentation and info message

2014-02-11 Thread Andrew Morton
On Mon, 10 Feb 2014 16:54:16 -0500 Johannes Weiner han...@cmpxchg.org wrote: How about this: we allow disabling the log message, but print the line of the disabling call so it's clear who dunnit. To make sure valuable info is not missing in bug reports, add counters for the two events in

Re: [patch] drop_caches: add some documentation and info message

2014-02-10 Thread Johannes Weiner
On Mon, Feb 10, 2014 at 12:51:02PM -0800, Andrew Morton wrote: > On Fri, 7 Feb 2014 16:26:01 -0500 Johannes Weiner wrote: > > > On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: > > > On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner > > > wrote: > > > > > > > @@ -63,6 +64,9 @@

RE: [patch] drop_caches: add some documentation and info message

2014-02-10 Thread Motohiro Kosaki
el@vger.kernel.org > Subject: Re: [patch] drop_caches: add some documentation and info > message > > On Fri, 7 Feb 2014 16:26:01 -0500 Johannes Weiner > wrote: > > > On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: > > > On Fri, 7 Feb 2014 13:13:32 -0500 Joh

Re: [patch] drop_caches: add some documentation and info message

2014-02-10 Thread Andrew Morton
On Fri, 7 Feb 2014 16:26:01 -0500 Johannes Weiner wrote: > On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: > > On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner > > wrote: > > > > > @@ -63,6 +64,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int > > > write, > > >

Re: [patch] drop_caches: add some documentation and info message

2014-02-10 Thread Andrew Morton
On Fri, 7 Feb 2014 16:26:01 -0500 Johannes Weiner han...@cmpxchg.org wrote: On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner han...@cmpxchg.org wrote: @@ -63,6 +64,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int

RE: [patch] drop_caches: add some documentation and info message

2014-02-10 Thread Motohiro Kosaki
: [patch] drop_caches: add some documentation and info message On Fri, 7 Feb 2014 16:26:01 -0500 Johannes Weiner han...@cmpxchg.org wrote: On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner han...@cmpxchg.org wrote

Re: [patch] drop_caches: add some documentation and info message

2014-02-10 Thread Johannes Weiner
On Mon, Feb 10, 2014 at 12:51:02PM -0800, Andrew Morton wrote: On Fri, 7 Feb 2014 16:26:01 -0500 Johannes Weiner han...@cmpxchg.org wrote: On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner han...@cmpxchg.org wrote:

Re: [patch] drop_caches: add some documentation and info message

2014-02-08 Thread Rafael Aquini
On Fri, Feb 07, 2014 at 01:13:32PM -0500, Johannes Weiner wrote: > On Fri, Feb 07, 2014 at 12:55:37PM -0500, Rik van Riel wrote: > > On 02/07/2014 12:40 PM, Johannes Weiner wrote: > > > > >@@ -59,6 +60,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int > > >write, > > > if (ret) > > >

Re: [patch] drop_caches: add some documentation and info message

2014-02-08 Thread Rafael Aquini
On Fri, Feb 07, 2014 at 01:13:32PM -0500, Johannes Weiner wrote: On Fri, Feb 07, 2014 at 12:55:37PM -0500, Rik van Riel wrote: On 02/07/2014 12:40 PM, Johannes Weiner wrote: @@ -59,6 +60,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, if (ret) return

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Johannes Weiner
On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: > On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner wrote: > > > @@ -63,6 +64,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int > > write, > > iterate_supers(drop_pagecache_sb, NULL); > > if

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Andrew Morton
On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner wrote: > @@ -63,6 +64,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, > iterate_supers(drop_pagecache_sb, NULL); > if (sysctl_drop_caches & 2) > drop_slab(); > +

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Rik van Riel
On 02/07/2014 01:13 PM, Johannes Weiner wrote: Would it be better to print this after the operation has completed? It would make more sense grammatically :-) Either way is fine with me, updated below to inform after the fact. Well, in principle the operation could take an arbitrarily long

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Johannes Weiner
On Fri, Feb 07, 2014 at 12:55:37PM -0500, Rik van Riel wrote: > On 02/07/2014 12:40 PM, Johannes Weiner wrote: > > >@@ -59,6 +60,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, > > if (ret) > > return ret; > > if (write) { > >+

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Rik van Riel
On 02/07/2014 12:40 PM, Johannes Weiner wrote: @@ -59,6 +60,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, if (ret) return ret; if (write) { + printk_ratelimited(KERN_INFO "%s (%d): dropped kernel caches: %d\n", +

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Rik van Riel
On 02/07/2014 12:40 PM, Johannes Weiner wrote: @@ -59,6 +60,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, if (ret) return ret; if (write) { + printk_ratelimited(KERN_INFO %s (%d): dropped kernel caches: %d\n, +

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Johannes Weiner
On Fri, Feb 07, 2014 at 12:55:37PM -0500, Rik van Riel wrote: On 02/07/2014 12:40 PM, Johannes Weiner wrote: @@ -59,6 +60,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, if (ret) return ret; if (write) { +printk_ratelimited(KERN_INFO %s

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Rik van Riel
On 02/07/2014 01:13 PM, Johannes Weiner wrote: Would it be better to print this after the operation has completed? It would make more sense grammatically :-) Either way is fine with me, updated below to inform after the fact. Well, in principle the operation could take an arbitrarily long

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Andrew Morton
On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner han...@cmpxchg.org wrote: @@ -63,6 +64,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, iterate_supers(drop_pagecache_sb, NULL); if (sysctl_drop_caches 2) drop_slab();

Re: [patch] drop_caches: add some documentation and info message

2014-02-07 Thread Johannes Weiner
On Fri, Feb 07, 2014 at 12:31:29PM -0800, Andrew Morton wrote: On Fri, 7 Feb 2014 13:13:32 -0500 Johannes Weiner han...@cmpxchg.org wrote: @@ -63,6 +64,9 @@ int drop_caches_sysctl_handler(ctl_table *table, int write, iterate_supers(drop_pagecache_sb, NULL);