lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150706135646.GD663@swordfish>
Date:	Mon, 6 Jul 2015 22:56:46 +0900
From:	Sergey Senozhatsky <sergey.senozhatsky@...il.com>
To:	Minchan Kim <minchan@...nel.org>
Cc:	Andrew Morton <akpm@...ux-foundation.org>, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org, sergey.senozhatsky.work@...il.com
Subject: Re: [PATCH v5 5/7] zsmalloc/zram: store compaction stats in zspool

On (07/06/15 22:27), Minchan Kim wrote:
> > `zs_compact_control' accounts the number of migrated objects but
> > it has a limited lifespan -- we lose it as soon as zs_compaction()
> > returns back to zram. It was fine, because (a) zram had it's own
> > counter of migrated objects and (b) only zram could trigger
> > compaction. However, this does not work for automatic pool
> > compaction (not issued by zram). To account objects migrated
> > during auto-compaction (issued by the shrinker) we need to store
> > this number in zs_pool.
> > 
> > A new zsmalloc zs_get_num_migrated() symbol exports zs_pool's
> > ->num_migrated counter, so we better start using it, rather than
> > continue keeping zram's own `num_migrated' copy in zram_stats.
> 
> If we introduce like this API we should make new another API when
> we want to introduce new stats. So I don't think it's a good idea.
> How about this?
> 
>         void zsmalloc_stats(struct zsmalloc_stats *stats);
> 
> So, we could return any upcoming stats without new API introduce.
> 

Hm, agree. Do you prefer me to fold this into this patch set or to do as
a separate work later?


P.S.

Sorry. Seems that my git send-email has some problems, so group-reply
in mutt does not work as expected.


	-ss
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ