MADV_DONTNEED is currently disabled for hugetlb mappings. This certainly
makes sense in shared file mappings as the pagecache maintains a reference
to the page and it will never be freed. However, it could be useful to
unmap and free pages in private mappings.
v1->v2:
Add patch to fix race caused by enabling the madv_dontneed feature.
Mike Kravetz (3):
mm: enable MADV_DONTNEED for hugetlb mappings
madvise: use zap_page_range_single for madvise dontneed
hugetlb: don't delete vma_lock in hugetlb MADV_DONTNEED processing
Rik van Riel (1):
mm,madvise,hugetlb: fix unexpected data loss with MADV_DONTNEED on
hugetlbfs
include/linux/hugetlb.h | 5 +++--
include/linux/mm.h | 6 +++++
include/linux/mm_types.h | 2 ++
mm/hugetlb.c | 28 ++++++++++++++----------
mm/madvise.c | 47 +++++++++++++++++++++++++++++++++++-----
mm/memory.c | 23 +++++++++++++++-----
6 files changed, 87 insertions(+), 24 deletions(-)
--
2.25.1