[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20080607141333.9C4C.KOSAKI.MOTOHIRO@jp.fujitsu.com>
Date: Sat, 07 Jun 2008 14:21:40 +0900
From: KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: kosaki.motohiro@...fujitsu.com, Rik van Riel <riel@...hat.com>,
linux-kernel@...r.kernel.org, lee.schermerhorn@...com
Subject: Re: [PATCH -mm 16/25] SHM_LOCKED pages are non-reclaimable
Hi
> > +static void check_move_noreclaim_page(struct page *page, struct zone *zone)
> > +{
> > +
> > + ClearPageNoreclaim(page); /* for page_reclaimable() */
>
> Confused. Didn't we just lose track of our NR_NORECLAIM accounting?
I think this code is right.
this patch track it by below code.
but comments adding is better?
> > + if (page_reclaimable(page, NULL)) {
> > + enum lru_list l = LRU_INACTIVE_ANON + page_file_cache(page);
> > + __dec_zone_state(zone, NR_NORECLAIM);
> > + list_move(&page->lru, &zone->list[l]);
> > + __inc_zone_state(zone, NR_INACTIVE_ANON + l);
> > + } else {
> > + /*
> > + * rotate noreclaim list
> > + */
> > + SetPageNoreclaim(page);
> > + list_move(&page->lru, &zone->list[LRU_NORECLAIM]);
> > + }
> > +}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists