The patch titled Subject: mm: hugetlb: fix pgoff computation when unmapping page from vma has been added to the -mm tree. Its filename is mm-hugetlb-fix-pgoff-computation-when-unmapping-page-from-vma.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find out what to do about this The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ From: Hillf Danton <dhillf@xxxxxxxxx> Subject: mm: hugetlb: fix pgoff computation when unmapping page from vma The computation for pgoff is incorrect, at least with (vma->vm_pgoff >> PAGE_SHIFT) involved. It is fixed with the available method if HPAGE_SIZE is concerned in page cache lookup. Signed-off-by: Hillf Danton <dhillf@xxxxxxxxx> Cc: Mel Gorman <mel@xxxxxxxxx> Cc: Michal Hocko <mhocko@xxxxxxx> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx> Cc: Andrea Arcangeli <aarcange@xxxxxxxxxx> Cc: David Rientjes <rientjes@xxxxxxxxxx> Reviewed-by: Michal Hocko <mhocko@xxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/hugetlb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff -puN mm/hugetlb.c~mm-hugetlb-fix-pgoff-computation-when-unmapping-page-from-vma mm/hugetlb.c --- a/mm/hugetlb.c~mm-hugetlb-fix-pgoff-computation-when-unmapping-page-from-vma +++ a/mm/hugetlb.c @@ -2315,8 +2315,7 @@ static int unmap_ref_private(struct mm_s * from page cache lookup which is in HPAGE_SIZE units. */ address = address & huge_page_mask(h); - pgoff = ((address - vma->vm_start) >> PAGE_SHIFT) - + (vma->vm_pgoff >> PAGE_SHIFT); + pgoff = linear_hugepage_index(vma, address); mapping = (struct address_space *)page_private(page); /* _ Subject: Subject: mm: hugetlb: fix pgoff computation when unmapping page from vma Patches currently in -mm which might be from dhillf@xxxxxxxxx are origin.patch linux-next.patch hugetlb-detect-race-upon-page-allocation-failure-during-cow.patch hugetlb-clarify-hugetlb_instantiation_mutex-usage.patch mm-compaction-push-isolate-search-base-of-compact-control-one-pfn-ahead.patch mm-hugetlb-fix-pgoff-computation-when-unmapping-page-from-vma.patch mm-hugetlb-fix-pgoff-computation-when-unmapping-page-from-vma-fix.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html