lkml.org 
[lkml]   [2001]   [Jan]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: try_to_swap_out() return value problem?


    On Thu, 4 Jan 2001, Rik van Riel wrote:

    > On Wed, 3 Jan 2001, Linus Torvalds wrote:
    > > On Thu, 4 Jan 2001, Marcelo Tosatti wrote:
    >
    > > I agree that the return value of swap_out() is fairly meaningless. It's
    > > been fairly meaningless for a long time now, and it's entirely possible
    > > that the "while (swap_out())" loop should be just something like
    > >
    > > /* Scan the VM space, try to clean up the page tables a bit */
    > > for (i = 0 ; i <= nr_threads >> priority; i++)
    > > swap_out(gfp_mask);
    >
    > The problem with this is that it means that page aging of
    > the mapped active pages is no longer balanced against the
    > aging of the unmapped active pages.

    Is there any reason to not just remove the lines

    if (!onlist)
    /* The page is still mapped, so it can't be freeable... */
    age_page_down_ageonly(page);

    /*
    * If the page is in active use by us, or if the page
    * is in active use by others, don't unmap it or
    * (worse) start unneeded IO.
    */
    if (page->age > 0)
    goto out_failed;

    from vmscan?

    They look like a complete hack, although an understandable one from the
    time when the virtual memory scan used to actually do IO as well.

    These days, if you think of the VM scanning as just a "shrink the page
    tables" operation, the down-aging doesn't make much sense. That will
    happen once the page has been moved to the lists, no?

    Linus

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

    \
     
     \ /
      Last update: 2005-03-22 12:52    [W:0.048 / U:181.828 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site