Bruno Haible <[email protected]> writes:

> Sounds fine for physmem_available and physmem_claimable.
>
> For physmem_total, I'm not sure. It is defined as "the total amount of
> physical memory". So, either
>   - leave physmem_total as it is, or
>   - invent a new function physmem_in_container,
>   - or add a 'bool in_container' parameter to physmem_total.

Perhaps a different function would be good. I'm thinking there may be
other platform-specific features that could be supported. E.g., FreeBSD
has jails, but I am not sure they have the ability to limit resources.
For the typical platform it can fallback to one of the physmem
functions.

I guess the hard part is thinking of a name. I considered "usablemem" at
first, but feel that it gives the impression you are returning the
difference if phyiscal memory and used memory at the current moment.

Collin

Reply via email to