Re: [PATCH] vmscan.c fixes

From: Marcelo Tosatti (marcelo@conectiva.com.br)
Date: Mon May 14 2001 - 17:25:32 EST


On Mon, 14 May 2001, Rik van Riel wrote:

> Hi Linus,
>
> the following patch does:

<snip>

> pg_data_t *pgdat = pgdat_list;
> int sum = 0;
> int freeable = nr_free_pages() + nr_inactive_clean_pages();
> + /* XXX: dynamic free target is complicated and may be wrong... */
> int freetarget = freepages.high + inactive_target / 3;

I think its better if we just remove " + inactive_target / 3" here ---
callers already account for the inactive_target when trying to
calculate the free target anyway.

Example:

static int refill_inactive(unsigned int gfp_mask, int user)
{
        int count, start_count, maxtry;

        count = inactive_shortage() + free_shortage();

...

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



This archive was generated by hypermail 2b29 : Tue May 15 2001 - 21:00:38 EST