lkml.org 
[lkml]   [2013]   [Feb]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 2/2] zram: gather statistics in a unique file
From
Date
On Sun, 2013-02-10 at 21:41 -0800, Greg Kroah-Hartman wrote:
> On Sun, Feb 10, 2013 at 08:29:06PM -0800, Davidlohr Bueso wrote:
> > Instead of having one sysfs file per zram statistic, group them all
> > in a single, reader-friendly, 'statistics' file. This not only reduces
> > code but is also makes it easier to visualize. The new file looks like:
> >
> > Number of reads: 24
> > Number of writes: 1055
> > Invalid IO: 0
> > Notify free: 0
> > Zero pages: 1042
> > Orig data size: 49152 bytes
> > Compressed data: 838 bytes
> > Total memory used: 53248 bytes
> >
> > Signed-off-by: Davidlohr Bueso <davidlohr.bueso@hp.com>
>
> No, please, the rule for sysfs is "one value per file", not files with
> lots of data that you need to parse.

Ok.

>
> If you want to do something like this, then do it in debugfs, but NEVER
> in sysfs.

So, you would you be open to having the statistics file in debugfs and
removing the individual files sysfs?

Thanks,
Davidlohr



\
 
 \ /
  Last update: 2013-02-11 19:41    [W:0.179 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site