lkml.org 
[lkml]   [2001]   [May]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: page_launder() bug
On Tue, 8 May 2001, Mikulas Patocka wrote:

> > + if (!dead_swap_page &&
> > + (PageTestandClearReferenced(page) || page->age > 0 ||
> > + (!page->buffers && page_count(page) > 1) ||
> > + page_ramdisk(page))) {
> ^^^^^^^^^^^^^^^^^^^^^^
> > del_page_from_inactive_dirty_list(page);
> > add_page_to_active_list(page);
> > continue;
>
> #define page_ramdisk(page) \
> (page->buffers && (MAJOR(page->buffers->b_dev) == RAMDISK_MAJOR))
>
> Are you sure that no one will release buffers under your hands?

Two things can happen:

1) the page gets ramdisk buffers _after_ we look at it first,
in this case the page isn't freeable and will be moved to
the active list on the next page_launder() loop

2) the page loses its ramdisk buffers after we look at it,
now the page is freeable, but we won't see it again until
it is moved from the active list to the inactive_dirty
list again

Any side effects harmful enough to warrant complicating this
test ?

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://distro.conectiva.com/

Send all your spam to aardvark@nl.linux.org (spam digging piggy)

-
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/

\
 
 \ /
  Last update: 2005-03-22 12:52    [W:0.129 / U:0.296 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site