linux-sg2042/arch/ia64
Naoya Horiguchi 83467efbdb mm: migrate: check movability of hugepage in unmap_and_move_huge_page()
Currently hugepage migration works well only for pmd-based hugepages
(mainly due to lack of testing,) so we had better not enable migration of
other levels of hugepages until we are ready for it.

Some users of hugepage migration (mbind, move_pages, and migrate_pages) do
page table walk and check pud/pmd_huge() there, so they are safe.  But the
other users (softoffline and memory hotremove) don't do this, so without
this patch they can try to migrate unexpected types of hugepages.

To prevent this, we introduce hugepage_migration_support() as an
architecture dependent check of whether hugepage are implemented on a pmd
basis or not.  And on some architecture multiple sizes of hugepages are
available, so hugepage_migration_support() also checks hugepage size.

Signed-off-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Hillf Danton <dhillf@gmail.com>
Cc: Wanpeng Li <liwanp@linux.vnet.ibm.com>
Cc: Mel Gorman <mgorman@suse.de>
Cc: Hugh Dickins <hughd@google.com>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: Rik van Riel <riel@redhat.com>
Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-09-11 15:57:49 -07:00
..
configs PCI: hotplug: Convert to be builtin only, not modular 2013-07-25 14:11:06 -06:00
dig Disintegrate asm/system.h for IA64 2012-03-28 18:30:02 +01:00
hp Add some casts to avoid warnings from efi_runtime_services_t members. 2013-07-10 10:09:04 -07:00
include Couple of small cleanups for ia64 2013-09-06 13:16:01 -07:00
kernel Merge branch 'akpm' (updates from Andrew Morton) 2013-07-03 17:12:13 -07:00
kvm KVM: Introduce kvm_arch_memslots_updated() 2013-07-18 12:29:25 +02:00
lib Fix common misspellings 2011-03-31 11:26:23 -03:00
mm mm: migrate: check movability of hugepage in unmap_and_move_huge_page() 2013-09-11 15:57:49 -07:00
oprofile Disintegrate asm/system.h for IA64 2012-03-28 18:30:02 +01:00
pci PCI: Replace printks with appropriate pr_*() 2013-06-18 09:49:23 -07:00
scripts scripts: change scripts to use system python instead of env 2010-02-02 14:33:56 +01:00
sn PCI changes for the v3.11 merge window: 2013-07-03 16:31:35 -07:00
uv ia64: change to new flag variables 2011-03-17 14:02:56 +01:00
xen [IA64] Delete __cpuinit usage from all ia64 users 2013-06-24 15:44:27 -07:00
Kconfig ARM: SoC platform changes for 3.12 2013-09-06 13:30:06 -07:00
Kconfig.debug
Makefile Merge commit 'v2.6.35' into kbuild/kbuild 2010-08-04 13:59:13 +02:00
install.sh
module.lds