The patch titled Subject: mm/hugetlb_cgroup: Add huge_page_order check to avoid incorrectly uncharge has been removed from the -mm tree. Its filename was hugetlb-cgroup-add-charge-uncharge-routines-for-hugetlb-cgroup-add-huge_page_order-check-to-avoid-incorrectly-uncharge.patch This patch was dropped because it was folded into hugetlb-cgroup-add-charge-uncharge-routines-for-hugetlb-cgroup.patch ------------------------------------------------------ From: Wanpeng Li <liwp@xxxxxxxxxxxxxxxxxx> Subject: mm/hugetlb_cgroup: Add huge_page_order check to avoid incorrectly uncharge alloc_huge_page() will call hugetlb_cgroup_charge_cgroup() to charge pages, the compound page have less than 3 pages will not charge to hugetlb cgroup. When alloc_huge_page fails it will call hugetlb_cgroup_uncharge_cgroup to uncharge pages, however, hugetlb_cgroup_uncharge_cgroup doesn't have huge_page_order check. That means it will uncharge pages even if the compound page have less than 3 pages. Add huge_page_order check to avoid this incorrectly uncharge. Reviewed-by: Michal Hocko <mhocko@xxxxxxx> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@xxxxxxxxxxxxxxxxxx> Signed-off-by: Wanpeng Li <liwp.linux@xxxxxxxxx> Cc: David Rientjes <rientjes@xxxxxxxxxx> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx> Cc: Hillf Danton <dhillf@xxxxxxxxx> Cc: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/hugetlb_cgroup.c | 3 +++ 1 file changed, 3 insertions(+) diff -puN mm/hugetlb_cgroup.c~hugetlb-cgroup-add-charge-uncharge-routines-for-hugetlb-cgroup-add-huge_page_order-check-to-avoid-incorrectly-uncharge mm/hugetlb_cgroup.c --- a/mm/hugetlb_cgroup.c~hugetlb-cgroup-add-charge-uncharge-routines-for-hugetlb-cgroup-add-huge_page_order-check-to-avoid-incorrectly-uncharge +++ a/mm/hugetlb_cgroup.c @@ -184,6 +184,9 @@ void hugetlb_cgroup_uncharge_cgroup(int if (hugetlb_cgroup_disabled() || !h_cg) return; + if (huge_page_order(&hstates[idx]) < HUGETLB_CGROUP_MIN_ORDER) + return; + res_counter_uncharge(&h_cg->hugepage[idx], csize); return; } _ Patches currently in -mm which might be from liwp@xxxxxxxxxxxxxxxxxx are origin.patch mm-prepare-for-removal-of-obsolete-proc-sys-vm-nr_pdflush_threads.patch hugetlb-cgroup-add-charge-uncharge-routines-for-hugetlb-cgroup.patch mm-remove-unused-lru_all_evictable.patch memcg-rename-mem_control_xxx-to-memcg_xxx.patch mm-memcg-complete-documentation-for-tcp-memcg-files.patch mm-memcg-mem_cgroup_relize_xxx_limit-can-guarantee-memcg-reslimit-=-memcg-memswlimit.patch mm-memcg-replace-inexistence-move_lock_page_cgroup-by-move_lock_mem_cgroup-in-comment.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