projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branches 'acpi-hotplug', 'acpi-sysfs' and 'acpi-sleep'
[firefly-linux-kernel-4.4.55.git]
/
mm
/
mempolicy.c
diff --git
a/mm/mempolicy.c
b/mm/mempolicy.c
index 4cc19f6ab6c6f84da6bb99955f5026a9bc066a76..eca4a3129129751208b41cfe808e9e31e5dc7b5f 100644
(file)
--- a/
mm/mempolicy.c
+++ b/
mm/mempolicy.c
@@
-525,8
+525,9
@@
static void queue_pages_hugetlb_pmd_range(struct vm_area_struct *vma,
#ifdef CONFIG_HUGETLB_PAGE
int nid;
struct page *page;
#ifdef CONFIG_HUGETLB_PAGE
int nid;
struct page *page;
+ spinlock_t *ptl;
-
spin_lock(&vma->vm_mm->page_table_lock
);
+
ptl = huge_pte_lock(hstate_vma(vma), vma->vm_mm, (pte_t *)pmd
);
page = pte_page(huge_ptep_get((pte_t *)pmd));
nid = page_to_nid(page);
if (node_isset(nid, *nodes) == !!(flags & MPOL_MF_INVERT))
page = pte_page(huge_ptep_get((pte_t *)pmd));
nid = page_to_nid(page);
if (node_isset(nid, *nodes) == !!(flags & MPOL_MF_INVERT))
@@
-536,7
+537,7
@@
static void queue_pages_hugetlb_pmd_range(struct vm_area_struct *vma,
(flags & MPOL_MF_MOVE && page_mapcount(page) == 1))
isolate_huge_page(page, private);
unlock:
(flags & MPOL_MF_MOVE && page_mapcount(page) == 1))
isolate_huge_page(page, private);
unlock:
- spin_unlock(
&vma->vm_mm->page_table_lock
);
+ spin_unlock(
ptl
);
#else
BUG();
#endif
#else
BUG();
#endif
@@
-2949,7
+2950,7
@@
void mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol)
return;
}
return;
}
- p += snprintf(p, maxlen, policy_modes[mode]);
+ p += snprintf(p, maxlen,
"%s",
policy_modes[mode]);
if (flags & MPOL_MODE_FLAGS) {
p += snprintf(p, buffer + maxlen - p, "=");
if (flags & MPOL_MODE_FLAGS) {
p += snprintf(p, buffer + maxlen - p, "=");