On Sat, 24 Mar 2001, Jonathan Morton wrote:
> free = atomic_read(&buffermem_pages);
> free += atomic_read(&page_cache_size);
> free += nr_free_pages();
> - free += nr_swap_pages;
> + /* Since getting swap info is expensive, see if our allocation can happen in
>physical RAM */
Actually, getting swap info is as cheap as reading the variable
nr_swap_pages. I should fix this in the OOM killer ;)
regards,
Rik
--
Virtual memory is like a game you can't win;
However, without VM there's truly nothing to lose...
http://www.surriel.com/
http://www.conectiva.com/ http://distro.conectiva.com.br/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Re: [PATCH] Prevent OOM from killing init Rik van Riel
- Re: [PATCH] Prevent OOM from killing init Christian Bodmer
- Re: [PATCH] Prevent OOM from killing init Horst von Brand
- Re: [PATCH] Prevent OOM from killing init Doug Ledford
- Re: [PATCH] Prevent OOM from killing ini... Mike Galbraith
- Re: [PATCH] Prevent OOM from killin... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Mike Galbraith
- Re: [PATCH] Prevent OOM from killin... Doug Ledford
- Re: [PATCH] Prevent OOM from ki... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Rik van Riel
- Re: [PATCH] Prevent OOM from ki... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Martin Dalecki
- Re: [PATCH] Prevent OOM from ki... Mike Galbraith
- Re: [PATCH] Prevent OOM from ki... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Mike Galbraith
- Re: [PATCH] Prevent OOM from ki... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Mike Galbraith
- Re: [PATCH] Prevent OOM from ki... Horst von Brand
- Re: [PATCH] Prevent OOM from ki... Jonathan Morton
- Re: [PATCH] Prevent OOM from ki... Rik van Riel

