1
0
Fork 0

[PATCH] migration: make sure there is no attempt to migrate reserved pages.

This ensures that reserved pages are not migrated.  Reserved pages
currently cause the WARN_ON to trigger in migrate_page_add()

Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
hifive-unleashed-5.1
Christoph Lameter 2006-01-12 01:05:20 -08:00 committed by Linus Torvalds
parent 1bc691d357
commit f4598c8b36
1 changed files with 3 additions and 1 deletions

View File

@ -208,6 +208,8 @@ static int check_pte_range(struct vm_area_struct *vma, pmd_t *pmd,
page = vm_normal_page(vma, addr, *pte);
if (!page)
continue;
if (PageReserved(page))
continue;
nid = page_to_nid(page);
if (node_isset(nid, *nodes) == !!(flags & MPOL_MF_INVERT))
continue;
@ -290,7 +292,7 @@ static inline int check_pgd_range(struct vm_area_struct *vma,
static inline int vma_migratable(struct vm_area_struct *vma)
{
if (vma->vm_flags & (
VM_LOCKED|VM_IO|VM_HUGETLB|VM_PFNMAP))
VM_LOCKED|VM_IO|VM_HUGETLB|VM_PFNMAP|VM_RESERVED))
return 0;
return 1;
}