]> Git Repo - linux.git/commit
mm/hugetlb: introduce set_huge_swap_pte_at() helper
authorPunit Agrawal <[email protected]>
Thu, 6 Jul 2017 22:39:50 +0000 (15:39 -0700)
committerLinus Torvalds <[email protected]>
Thu, 6 Jul 2017 23:24:34 +0000 (16:24 -0700)
commite5251fd43007f9e1155331f0fa30685604a8e3a1
tree380002511e7dec6edf00242df7c18f900eb74d32
parent9386fac34c7cbe39013410b01348e284652ca1cf
mm/hugetlb: introduce set_huge_swap_pte_at() helper

set_huge_pte_at(), an architecture callback to populate hugepage ptes,
does not provide the range of virtual memory that is targeted.  This
leads to ambiguity when dealing with swap entries on architectures that
support hugepages consisting of contiguous ptes.

Fix the problem by introducing an overridable helper that is called when
populating the page tables with swap entries.  The size of the targeted
region is provided to the helper to help determine the number of entries
to be updated.

Provide a default implementation that maintains the current behaviour.

[[email protected]: v4]
Link: http://lkml.kernel.org/r/[email protected]
[[email protected]: add an empty definition for set_huge_swap_pte_at()]
Link: http://lkml.kernel.org/r/[email protected]
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Punit Agrawal <[email protected]>
Acked-by: Steve Capper <[email protected]>
Cc: Mike Kravetz <[email protected]>
Cc: "Aneesh Kumar K.V" <[email protected]>
Cc: Catalin Marinas <[email protected]>
Cc: Will Deacon <[email protected]>
Cc: Naoya Horiguchi <[email protected]>
Cc: "Kirill A. Shutemov" <[email protected]>
Cc: Mark Rutland <[email protected]>
Cc: Hillf Danton <[email protected]>
Cc: Michal Hocko <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
include/linux/hugetlb.h
mm/hugetlb.c
This page took 0.057177 seconds and 4 git commands to generate.