aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mm.h
diff options
context:
space:
mode:
authorMel Gorman <mgorman@suse.de>2012-10-25 08:16:32 -0400
committerMel Gorman <mgorman@suse.de>2012-12-11 09:42:44 -0500
commit4b10e7d562c90d0a72f324832c26653947a07381 (patch)
tree733e0fc3ac3fdfe27a312bc72e4ffb07bbf0aa56 /include/linux/mm.h
parentb24f53a0bea38b266d219ee651b22dba727c44ae (diff)
mm: mempolicy: Implement change_prot_numa() in terms of change_protection()
This patch converts change_prot_numa() to use change_protection(). As pte_numa and friends check the PTE bits directly it is necessary for change_protection() to use pmd_mknuma(). Hence the required modifications to change_protection() are a little clumsy but the end result is that most of the numa page table helpers are just one or two instructions. Signed-off-by: Mel Gorman <mgorman@suse.de>
Diffstat (limited to 'include/linux/mm.h')
-rw-r--r--include/linux/mm.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 471185e29bab..d04c2f0aab36 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -1080,7 +1080,7 @@ extern unsigned long do_mremap(unsigned long addr,
1080 unsigned long flags, unsigned long new_addr); 1080 unsigned long flags, unsigned long new_addr);
1081extern unsigned long change_protection(struct vm_area_struct *vma, unsigned long start, 1081extern unsigned long change_protection(struct vm_area_struct *vma, unsigned long start,
1082 unsigned long end, pgprot_t newprot, 1082 unsigned long end, pgprot_t newprot,
1083 int dirty_accountable); 1083 int dirty_accountable, int prot_numa);
1084extern int mprotect_fixup(struct vm_area_struct *vma, 1084extern int mprotect_fixup(struct vm_area_struct *vma,
1085 struct vm_area_struct **pprev, unsigned long start, 1085 struct vm_area_struct **pprev, unsigned long start,
1086 unsigned long end, unsigned long newflags); 1086 unsigned long end, unsigned long newflags);
@@ -1552,7 +1552,7 @@ static inline pgprot_t vm_get_page_prot(unsigned long vm_flags)
1552#endif 1552#endif
1553 1553
1554#ifdef CONFIG_ARCH_USES_NUMA_PROT_NONE 1554#ifdef CONFIG_ARCH_USES_NUMA_PROT_NONE
1555void change_prot_numa(struct vm_area_struct *vma, 1555unsigned long change_prot_numa(struct vm_area_struct *vma,
1556 unsigned long start, unsigned long end); 1556 unsigned long start, unsigned long end);
1557#endif 1557#endif
1558 1558