• H
    ksm: reorganize ksm_check_stable_tree · ee0ea59c
    Hugh Dickins 提交于
    Memory hotremove's ksm_check_stable_tree() is pitifully inefficient
    (restarting whenever it finds a stale node to remove), but rearrange so
    that at least it does not needlessly restart from nid 0 each time.  And
    add a couple of comments: here is why we keep pfn instead of page.
    Signed-off-by: NHugh Dickins <hughd@google.com>
    Cc: Rik van Riel <riel@redhat.com>
    Cc: Petr Holasek <pholasek@redhat.com>
    Cc: Andrea Arcangeli <aarcange@redhat.com>
    Cc: Izik Eidus <izik.eidus@ravellosystems.com>
    Cc: Gerald Schaefer <gerald.schaefer@de.ibm.com>
    Cc: KOSAKI Motohiro <kosaki.motohiro@gmail.com>
    Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
    ee0ea59c
ksm.c 57.6 KB