The patch titled Subject: hwpoison, hugetlbfs: fix RSS-counter warning has been added to the -mm tree. Its filename is hwpoison-hugetlbfs-fix-rss-counter-warning.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 *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Naoya Horiguchi <n-horiguchi@xxxxxxxxxxxxx> Subject: hwpoison, hugetlbfs: fix RSS-counter warning Memory error handling on hugepages can break a RSS counter, which emits a message like "Bad rss-counter state mm:ffff88040abecac0 idx:1 val:-1". This is because PageAnon returns true for hugepage (this behavior is necessary for reverse mapping to work on hugetlbfs). Signed-off-by: Naoya Horiguchi <n-horiguchi@xxxxxxxxxxxxx> Cc: Andi Kleen <andi.kleen@xxxxxxxxx> Cc: Tony Luck <tony.luck@xxxxxxxxx> Cc: Wu Fengguang <fengguang.wu@xxxxxxxxx> Cc: Aneesh Kumar K.V <aneesh.kumar@xxxxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/rmap.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff -puN mm/rmap.c~hwpoison-hugetlbfs-fix-rss-counter-warning mm/rmap.c --- a/mm/rmap.c~hwpoison-hugetlbfs-fix-rss-counter-warning +++ a/mm/rmap.c @@ -1249,7 +1249,9 @@ int try_to_unmap_one(struct page *page, update_hiwater_rss(mm); if (PageHWPoison(page) && !(flags & TTU_IGNORE_HWPOISON)) { - if (PageAnon(page)) + if (PageHuge(page)) + ; + else if (PageAnon(page)) dec_mm_counter(mm, MM_ANONPAGES); else dec_mm_counter(mm, MM_FILEPAGES); _ Patches currently in -mm which might be from n-horiguchi@xxxxxxxxxxxxx are hwpoison-fix-action_result-to-print-out-dirty-clean.patch mm-print-out-information-of-file-affected-by-memory-error.patch hwpoison-hugetlbfs-fix-warning-on-freeing-hwpoisoned-hugepage.patch hwpoison-hugetlbfs-fix-bad-pmd-warning-in-unmapping-hwpoisoned-hugepage.patch hwpoison-hugetlbfs-fix-rss-counter-warning.patch hwpoison-hugetlbfs-fix-rss-counter-warning-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