Re: [PATCH v6 6/7] zsmalloc: account the number of compacted pages

From: Sergey Senozhatsky
Date: Tue Jul 07 2015 - 10:22:22 EST


On (07/07/15 22:39), Minchan Kim wrote:
[..]
> > struct zs_pool_stats {
> > - /* How many objects were migrated */
> > - u64 num_migrated;
> > + /* How many pages were migrated (freed) */
> > + u64 pages_compacted;
>
> Hmm, if we account it as page unit, unsigned long is enough for 32bit.

Well, this is a 'how many pages were freed overall' counter. We don't
control the lifetime of device, so I think it can be bigger than 4 bytes
in some `extreme' cases.

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