[lkml]   [2003]   [Jul]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: Software suspend testing in 2.6.0-test1

    > > If this patch is an acceptable approach to fix the problem,
    > Seems reasonable.
    > > the balance_pgdat function should probably be cleaned up.
    > Well it was rather bolted on the side of the kswapd code. But from an API
    > perspective, being able to tell it how many page to free is a bit more
    > flexible. Minor point.
    > However I'm trying to remember why the code exists at all. Why doesn't
    > swsusp just allocate lots of pages then free them again?

    Because that either

    a) does not free enough pages or

    b) triggers OOM killer.

    It was actually your idea, IIRC ;-).

    Ahha, you seem to be addressing that in your code. Peter, perhaps you
    want to test that one?

    > Something like:
    > LIST_HEAD(list);
    > int sleep_count = 0;
    > while (sleep_count < 10) {
    > page = __alloc_pages(0, GFP_ATOMIC);
    > if (page) {
    > list_add(&page->list, &list);
    > } else {
    > blk_congestion_wait(WRITE, HZ/20);
    > sleep_count++;
    > }
    > }
    > <free all the pages on `list'>

    When do you have a heart between your knees?
    [Johanka's followup: and *two* hearts?]
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:46    [W:0.020 / U:9.624 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site