• R
    vmscan: kswapd carefully call compaction · 7be62de9
    Rik van Riel 提交于
    With CONFIG_COMPACTION enabled, kswapd does not try to free contiguous
    free pages, even when it is woken for a higher order request.
    
    This could be bad for eg.  jumbo frame network allocations, which are done
    from interrupt context and cannot compact memory themselves.  Higher than
    before allocation failure rates in the network receive path have been
    observed in kernels with compaction enabled.
    
    Teach kswapd to defragment the memory zones in a node, but only if
    required and compaction is not deferred in a zone.
    
    [akpm@linux-foundation.org: reduce scope of zones_need_compaction]
    Signed-off-by: NRik van Riel <riel@redhat.com>
    Acked-by: NMel Gorman <mel@csn.ul.ie>
    Cc: Andrea Arcangeli <aarcange@redhat.com>
    Cc: Johannes Weiner <hannes@cmpxchg.org>
    Cc: Minchan Kim <minchan.kim@gmail.com>
    Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
    Cc: Hillf Danton <dhillf@gmail.com>
    Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
    7be62de9
compaction.c 20.8 KB