Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754120AbbKJP7D (ORCPT ); Tue, 10 Nov 2015 10:59:03 -0500 Received: from mail-wm0-f49.google.com ([74.125.82.49]:36990 "EHLO mail-wm0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752553AbbKJP7A convert rfc822-to-8bit (ORCPT ); Tue, 10 Nov 2015 10:59:00 -0500 From: Michal Nazarewicz To: Joonsoo Kim , Andrew Morton Cc: Minchan Kim , Mel Gorman , Vlastimil Babka , "Kirill A. Shutemov" , linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, Joonsoo Kim Subject: Re: [PATCH 1/2] mm: introduce page reference manipulation functions In-Reply-To: <1447053784-27811-1-git-send-email-iamjoonsoo.kim@lge.com> Organization: http://mina86.com/ References: <1447053784-27811-1-git-send-email-iamjoonsoo.kim@lge.com> User-Agent: Notmuch/0.19+53~g2e63a09 (http://notmuchmail.org) Emacs/25.0.50.1 (x86_64-unknown-linux-gnu) X-Face: PbkBB1w#)bOqd`iCe"Ds{e+!C7`pkC9a|f)Qo^BMQvy\q5x3?vDQJeN(DS?|-^$uMti[3D*#^_Ts"pU$jBQLq~Ud6iNwAw_r_o_4]|JO?]}P_}Nc&"p#D(ZgUb4uCNPe7~a[DbPG0T~!&c.y$Ur,=N4RT>]dNpd;KFrfMCylc}gc??'U2j,!8%xdD Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAJFBMVEWbfGlUPDDHgE57V0jUupKjgIObY0PLrom9mH4dFRK4gmjPs41MxjOgAAACQElEQVQ4jW3TMWvbQBQHcBk1xE6WyALX1069oZBMlq+ouUwpEQQ6uRjttkWP4CmBgGM0BQLBdPFZYPsyFUo6uEtKDQ7oy/U96XR2Ux8ehH/89Z6enqxBcS7Lg81jmSuujrfCZcLI/TYYvbGj+jbgFpHJ/bqQAUISj8iLyu4LuFHJTosxsucO4jSDNE0Hq3hwK/ceQ5sx97b8LcUDsILfk+ovHkOIsMbBfg43VuQ5Ln9YAGCkUdKJoXR9EclFBhixy3EGVz1K6eEkhxCAkeMMnqoAhAKwhoUJkDrCqvbecaYINlFKSRS1i12VKH1XpUd4qxL876EkMcDvHj3s5RBajHHMlA5iK32e0C7VgG0RlzFPvoYHZLRmAC0BmNcBruhkE0KsMsbEc62ZwUJDxWUdMsMhVqovoT96i/DnX/ASvz/6hbCabELLk/6FF/8PNpPCGqcZTGFcBhhAaZZDbQPaAB3+KrWWy2XgbYDNIinkdWAFcCpraDE/knwe5DBqGmgzESl1p2E4MWAz0VUPgYYzmfWb9yS4vCvgsxJriNTHoIBz5YteBvg+VGISQWUqhMiByPIPpygeDBE6elD973xWwKkEiHZAHKjhuPsFnBuArrzxtakRcISv+XMIPl4aGBUJm8Emk7qBYU8IlgNEIpiJhk/No24jHwkKTFHDWfPniR4iw5vJaw2nzSjfq2zffcE/GDjRC2dn0J0XwPAbDL84TvaFCJEU4Oml9pRyEUhR3Cl2t01AoEjRbs0sYugp14/4X5n4pU4EHHnMAAAAAElFTkSuQmCC X-PGP: 50751FF4 X-PGP-FP: AC1F 5F5C D418 88F8 CC84 5858 2060 4012 5075 1FF4 X-Hashcash: 1:20:151110:linux-api@vger.kernel.org::E46PWoqZtvgc05W+:0000000000000000000000000000000000000BW6 X-Hashcash: 1:20:151110:minchan@kernel.org::o/9OScm6rXS7Dq/7:00000000000000000000000000000000000000000000imw X-Hashcash: 1:20:151110:akpm@linux-foundation.org::ScXU6MzwTfHtXAsb:0000000000000000000000000000000000000wqn X-Hashcash: 1:20:151110:iamjoonsoo.kim@lge.com::4Hrd7KCtIAJay6dx:0000000000000000000000000000000000000001TTd X-Hashcash: 1:20:151110:vbabka@suse.cz::x3gRWfCBLmPBTD9O:0000oPb X-Hashcash: 1:20:151110:mgorman@suse.de::ZJHnqVj8OQcx8wRB:001MFF X-Hashcash: 1:20:151110:kirill.shutemov@linux.intel.com::8MSaI/v2SCEG2+49:0000000000000000000000000000002fQV X-Hashcash: 1:20:151110:linux-kernel@vger.kernel.org::VOwu9bahm9KS+y3m:0000000000000000000000000000000005VWf X-Hashcash: 1:20:151110:linux-mm@kvack.org::SjUmYTl1ld1w59JJ:0000000000000000000000000000000000000000000654R X-Hashcash: 1:20:151110:js1304@gmail.com::VcHdplUiZZklAf/S:07IdL Date: Tue, 10 Nov 2015 16:58:56 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2836 Lines: 54 On Mon, Nov 09 2015, Joonsoo Kim wrote: > Success of CMA allocation largely depends on success of migration > and key factor of it is page reference count. Until now, page reference > is manipulated by direct calling atomic functions so we cannot follow up > who and where manipulate it. Then, it is hard to find actual reason > of CMA allocation failure. CMA allocation should be guaranteed to succeed > so finding offending place is really important. > > In this patch, call sites where page reference is manipulated are converted > to introduced wrapper function. This is preparation step to add tracepoint > to each page reference manipulation function. With this facility, we can > easily find reason of CMA allocation failure. There is no functional change > in this patch. > > Signed-off-by: Joonsoo Kim Acked-by: Michal Nazarewicz > --- > arch/mips/mm/gup.c | 2 +- > arch/powerpc/mm/mmu_context_hash64.c | 3 +- > arch/powerpc/mm/pgtable_64.c | 2 +- > arch/x86/mm/gup.c | 2 +- > drivers/block/aoe/aoecmd.c | 4 +- > drivers/net/ethernet/freescale/gianfar.c | 2 +- > drivers/net/ethernet/intel/fm10k/fm10k_main.c | 2 +- > drivers/net/ethernet/intel/igb/igb_main.c | 2 +- > drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +- > drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 2 +- > drivers/net/ethernet/mellanox/mlx4/en_rx.c | 7 +-- > drivers/net/ethernet/sun/niu.c | 2 +- > include/linux/mm.h | 21 ++----- > include/linux/page_ref.h | 76 +++++++++++++++++++++++ > include/linux/pagemap.h | 19 +----- > mm/huge_memory.c | 6 +- > mm/internal.h | 5 -- > mm/memory_hotplug.c | 4 +- > mm/migrate.c | 10 +-- > mm/page_alloc.c | 6 +- > mm/vmscan.c | 6 +- > 21 files changed, 114 insertions(+), 71 deletions(-) > create mode 100644 include/linux/page_ref.h > -- Best regards, _ _ .o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o ..o | Computer Science, ミハウ “mina86” ナザレヴイツ (o o) ooo +---------ooO--(_)--Ooo-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/