Re: + zram-support-compaction.patch added to -mm tree

2015-03-09 Thread Sergey Senozhatsky
On (03/09/15 23:56), Minchan Kim wrote: > > in zram_slot_free_notify() and zram_rw_page() we don't have request queue, > > request, > > etc. so it's a bit troubling. > > I skim the code so I might miss something. > > zram_slot_free_notify is just to free allocated space on zsmalloc so > it's not

Re: + zram-support-compaction.patch added to -mm tree

2015-03-09 Thread Minchan Kim
Hello, On Mon, Mar 09, 2015 at 03:48:56PM +0900, Sergey Senozhatsky wrote: > On (03/09/15 11:21), Minchan Kim wrote: > > > I was thinking for some time already about splitting stats that we > > > export in two categories and, thus, two files: IO_stats and MM_stats. > > > > > > zram/io_stat > > >

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Sergey Senozhatsky
On (03/09/15 11:21), Minchan Kim wrote: > > I was thinking for some time already about splitting stats that we > > export in two categories and, thus, two files: IO_stats and MM_stats. > > > > zram/io_stat > > > > s*printf( num_reads, num_writes, failed_reads, failed_writes, etc.) > > Some of it

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Minchan Kim
On Mon, Mar 09, 2015 at 11:07:17AM +0900, Sergey Senozhatsky wrote: > On (03/09/15 10:47), Minchan Kim wrote: > > > > > > > > It's not enough. What I want to know is compaction efficiency per > > > > client of > > > > zsmalloc(ie, zram). > > > > > > > > > > so what a typical user can do with th

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Sergey Senozhatsky
On (03/09/15 10:47), Minchan Kim wrote: > > > > > > It's not enough. What I want to know is compaction efficiency per client > > > of > > > zsmalloc(ie, zram). > > > > > > > so what a typical user can do with this information? isn't it an entirely > > debug info that makes some hidden sense onl

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Minchan Kim
On Mon, Mar 09, 2015 at 10:27:28AM +0900, Sergey Senozhatsky wrote: > On (03/09/15 10:05), Minchan Kim wrote: > > > well, to be fair, compaction is a zsmalloc internal. zram has nothing to > > > do with > > > it. > > > > > > but do we we even need this stat? it seems that > > > > > >mem_tota

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Sergey Senozhatsky
On (03/09/15 10:05), Minchan Kim wrote: > > well, to be fair, compaction is a zsmalloc internal. zram has nothing to do > > with > > it. > > > > but do we we even need this stat? it seems that > > > >mem_total_used (before compaction) - mem_total_user (after comapction) > > > > will give us

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Minchan Kim
On Mon, Mar 09, 2015 at 09:57:18AM +0900, Sergey Senozhatsky wrote: > On (03/09/15 09:49), Minchan Kim wrote: > > > rather a discussion question. > > > > > > Minchan, do you want to provide num_migrated as part of zsmalloc stats > > > rather > > > than having yet another zram attr? we already pro

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Sergey Senozhatsky
On (03/09/15 09:49), Minchan Kim wrote: > > rather a discussion question. > > > > Minchan, do you want to provide num_migrated as part of zsmalloc stats > > rather > > than having yet another zram attr? we already provide zsmalloc stats and > > this > > type of information seems to belong there.

Re: + zram-support-compaction.patch added to -mm tree

2015-03-08 Thread Minchan Kim
Hello Sergey, On Thu, Mar 05, 2015 at 02:29:42PM +0900, Sergey Senozhatsky wrote: > On (03/04/15 14:02), a...@linux-foundation.org wrote: > > +What: /sys/block/zram/compact > > +Date: August 2015 > > +Contact: Minchan Kim > > +Description: > > + The compact f

Re: + zram-support-compaction.patch added to -mm tree

2015-03-05 Thread Sergey Senozhatsky
On (03/05/15 14:29), Sergey Senozhatsky wrote: > On (03/04/15 14:02), a...@linux-foundation.org wrote: > > +What: /sys/block/zram/compact > > +Date: August 2015 > > +Contact: Minchan Kim > > +Description: > > + The compact file is write-only and trigger compac

Re: + zram-support-compaction.patch added to -mm tree

2015-03-04 Thread Sergey Senozhatsky
On (03/04/15 14:02), a...@linux-foundation.org wrote: > +What:/sys/block/zram/compact > +Date:August 2015 > +Contact: Minchan Kim > +Description: > + The compact file is write-only and trigger compaction for > + allocator zrm uses. The al

Re: + zram-support-compaction.patch added to -mm tree

2015-03-04 Thread Minchan Kim
Hello Sergey, On Thu, Mar 05, 2015 at 09:18:45AM +0900, Sergey Senozhatsky wrote: > Hello, > > On (03/04/15 14:02), a...@linux-foundation.org wrote: > [..] > > +++ a/drivers/block/zram/zram_drv.c > > @@ -70,6 +70,27 @@ static inline struct zram *dev_to_zram(s > > return (struct zram *)dev_to_

Re: + zram-support-compaction.patch added to -mm tree

2015-03-04 Thread Sergey Senozhatsky
Hello, On (03/04/15 14:02), a...@linux-foundation.org wrote: [..] > +++ a/drivers/block/zram/zram_drv.c > @@ -70,6 +70,27 @@ static inline struct zram *dev_to_zram(s > return (struct zram *)dev_to_disk(dev)->private_data; > } > > +static ssize_t compact_store(struct device *dev, > +