• R
    powerpc: Make the CMM memory hotplug aware · 14b8a76b
    Robert Jennings 提交于
    The Collaborative Memory Manager (CMM) module allocates individual pages
    over time that are not migratable.  On a long running system this can
    severely impact the ability to find enough pages to support a hotplug
    memory remove operation.
    
    This patch adds a memory isolation notifier and a memory hotplug notifier.
    The memory isolation notifier will return the number of pages found in
    the range specified.  This is used to determine if all of the used pages
    in a pageblock are owned by the balloon (or other entities in the notifier
    chain).  The hotplug notifier will free pages in the range which is to be
    removed.  The priority of this hotplug notifier is low so that it will be
    called near last, this helps avoids removing loaned pages in operations
    that fail due to other handlers.
    
    CMM activity will be halted when hotplug remove operations are active and
    resume activity after a delay period to allow the hypervisor time to
    adjust.
    Signed-off-by: NRobert Jennings <rcj@linux.vnet.ibm.com>
    Cc: Mel Gorman <mel@csn.ul.ie>
    Cc: Ingo Molnar <mingo@elte.hu>
    Cc: Brian King <brking@linux.vnet.ibm.com>
    Cc: Paul Mackerras <paulus@samba.org>
    Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
    Cc: Gerald Schaefer <geralds@linux.vnet.ibm.com>
    Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
    Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
    Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
    14b8a76b
cmm.c 18.4 KB