Re: [patch -rss] Make RSS accounting display more user friendly

From: Balbir Singh
Date: Fri Jun 22 2007 - 23:48:26 EST


On 6/22/07, Paul Menage <menage@xxxxxxxxxx> wrote:
On 6/21/07, Pavel Emelianov <xemul@xxxxxxxxxx> wrote:
>
> Nothing wrong, but currently they are shown in "natural" points, i.e. in
> those that the controller accounts them in. For RSS controller the natural
> point is "page", but auto-converting them from pages to bytes is wrong, as
> not all the controllers account in pages.

This exposes more implementation detail than I think is good.
Something like a memory controller should use a more abstract
interface like bytes, and do the conversion to/from its internal
"natural" units like pages internally. E.g. the example cpu accounting
controller that I included with my patch set reports usage in
milliseconds, even though it counts internally in jiffies.

Hi, Paul,

Bytes are too fine grained. Do we also accept the input in bytes? kB
are probably the best, but then with the limit set to LONG_MAX, kB
wrap around (if the input is in units of pages) on 64 bit machines
(the sameapplies to bytes as well).

The problem with input in bytes is that the user will have to ensure
that the input is
a multiple of page size, which implies that she would need to use the
calculator every time.
-
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/