Re: [PATCH] __free_pages_ok oops

From: Rik van Riel (riel@conectiva.com.br)
Date: Thu Feb 07 2002 - 09:56:34 EST


On Thu, 7 Feb 2002, Hugh Dickins wrote:
> On Thu, 7 Feb 2002, Rik van Riel wrote:
> > On Thu, 7 Feb 2002, Hugh Dickins wrote:
> > >
> > > If this were a common case where many pages end up, yes, we'd
> > > need a separate special list; but it's a very rare case
> >
> > Think of a web or ftp server doing nothing but sendfile()
>
> Aren't the sendfile() pages in the page cache, and normally taken
> off LRU at the same time as removed from page cache, in shrink_cache?

You're right.

> I imagined (not yet tried) in shrink_cache, something like:

> if (unlikely(!page_count(page))) {
> page_cache_get(page);
> __lru_cache_del(page);
> page_cache_release(page);
> continue;
> }

I guess this should work.

regards,

Rik

-- 
"Linux holds advantages over the single-vendor commercial OS"
    -- Microsoft's "Competing with Linux" document

http://www.surriel.com/ http://distro.conectiva.com/

- 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 : Thu Feb 07 2002 - 21:01:02 EST