Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp310312imj; Sat, 16 Feb 2019 00:37:07 -0800 (PST) X-Google-Smtp-Source: AHgI3IbbegWOmz1NYKPZ1rvV7D1hDahvA2vVhpkmQ1ut9kT0y0o0Hw8Ox1sc7DyNQdacMUZ20plN X-Received: by 2002:a63:4384:: with SMTP id q126mr9145574pga.160.1550306227746; Sat, 16 Feb 2019 00:37:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550306227; cv=none; d=google.com; s=arc-20160816; b=cJqk8Fpze9ECLZC3+rnKcjI/uEo/cxMvY3Pqp28juxC43x3HAienrVzUNKgcgFQ07b 7Dgps4LpUNR6tfheISa6p50NWYFVQvLMuLcfxI3GpTuq2D+3vJA2dE1JgKaIR+ffPf9t 85wvmq9QRj31/2jbO49DwGKwiq6maFemP84E/8LZFNgXuYtkQS2lsAuLhBFJXHMnRhKJ LcGFibExjyMEsBZaoz1rhfadXJh2y+gZV18MK5Jqw3Ghs8wQ9WukZCTHUFDm+JT6ElEV HUrt5nslNw9a56etLY23wTC1dPZ0Shfut/nncqxZ90HvSDIoYoCo/jvChipo/euEQ2O5 XdPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :reply-to:references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-signature; bh=s+M9Q1Dn/74r7Hqs3gLQcg1STi/Xk0kU2xFV7ZybJ5M=; b=PZwyDOIG0elcchb9I8tchIdqAROGfWwKOUxgBqa4mhbdn6HQKhLvxqMtwBfLxH54Nc MS6pCM9vHuI4CPu82XIIzZDWDYePWFpvPMDoF0jxyO5JbYVdCoceq6OEdqdyf8nuwbGB FzZM1QhlEPmtpF4cRethOn7ulSZrm2E3uq8zoJWTF5KCA3/RsxZEIBhucAbZeclLANiD X/V2/h3b9XJ9t5J5f9TpxB5FEKJlyudyMwtZ4B1ns/1+eneSJIVZcdvqqGw/gwKjDYCB kw8T5QmXrqEcCPQ+F8htkqVOfS/w5yqhDV7hX/HvIil6NRyrbc6o5jdyBF0wwAkX+yCg 99uQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sent.com header.s=fm2 header.b=LMQQ6Foj; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b="OIv/vxn8"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sent.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o9si6207163pll.303.2019.02.16.00.36.52; Sat, 16 Feb 2019 00:37:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@sent.com header.s=fm2 header.b=LMQQ6Foj; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b="OIv/vxn8"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sent.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2393767AbfBOWLI (ORCPT + 99 others); Fri, 15 Feb 2019 17:11:08 -0500 Received: from wout2-smtp.messagingengine.com ([64.147.123.25]:36083 "EHLO wout2-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2393204AbfBOWJT (ORCPT ); Fri, 15 Feb 2019 17:09:19 -0500 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id 7BBD7310A; Fri, 15 Feb 2019 17:09:17 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Fri, 15 Feb 2019 17:09:18 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sent.com; h=from :to:cc:subject:date:message-id:in-reply-to:references:reply-to :mime-version:content-transfer-encoding; s=fm2; bh=s+M9Q1Dn/74r7 Hqs3gLQcg1STi/Xk0kU2xFV7ZybJ5M=; b=LMQQ6FojPBEWUxYcZyupLkHS7Gi6/ lCmVLgDcfuWz9E42THOfhFiodqUK9AGh/8qXtf2Oz92BOz8GBlswGNkO10eAsI8p MnPC+Z6phDvGEVAQJx3NS0hZBEIrm+Zykik8xVKRicMjNuMx/Q5Pseh/BkMkdOPE mVyJTbEZepYPiFmRSwzOYwIyafdxqPSjfy8tMAvmCxtYnm+Y5m7FfyqLmSfsD7be gHmAJQ+E9QlOo7671DKVipxixMf2koJcueOM/TJhVPBR2JG35KIyWX93ehf6wXz+ HmTH5oKrFuZVcMTORI4XtdgikLmA6D3ixeLcAvtgo6XjQ+Wyo8Olt3AEg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:reply-to:subject :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=s+M9Q1Dn/74r7Hqs3gLQcg1STi/Xk0kU2xFV7ZybJ5M=; b=OIv/vxn8 z8uHrE0XwEs5J3iyx9QT7uKYL6ToBVMAWN5DFv8SVn3iTZNUSJa8TdtF/FnfxOuW ydrpe04VTkGrfL2oJenrQ5PVE1XQ0mc5KNg3vxskG6exsbG63ILI6X+rRapRgWHH WaHKW16CkiQF1x7giugKKyZPqsUr9bh2OQTSCV7JPYHe/CwzqTd+aNnYtMASt+vs HLA4JPfbL8CjOvnHUBvbESMGVjEzXx4Ar7HNpQl+4aggb0Gyi2rJXOu0E8F2cZ1T 4tU6/j3coPB5+DfUjENijh2Nd+dv0CucbaI06/1vRIFVfLjSTxVRasibOPW5C5gr OLmyU8z8PTtlAg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedtledruddtjedgudehkecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfhuthenuceurghilhhouhhtmecu fedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufffkf fojghfrhgggfestdekredtredttdenucfhrhhomhepkghiucgjrghnuceoiihirdihrghn sehsvghnthdrtghomheqnecukfhppedvudeirddvvdekrdduuddvrddvvdenucfrrghrrg hmpehmrghilhhfrhhomhepiihirdihrghnsehsvghnthdrtghomhenucevlhhushhtvghr ufhiiigvpeel X-ME-Proxy: Received: from nvrsysarch5.nvidia.com (thunderhill.nvidia.com [216.228.112.22]) by mail.messagingengine.com (Postfix) with ESMTPA id 922BBE4511; Fri, 15 Feb 2019 17:09:15 -0500 (EST) From: Zi Yan To: linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: Dave Hansen , Michal Hocko , "Kirill A . Shutemov" , Andrew Morton , Vlastimil Babka , Mel Gorman , John Hubbard , Mark Hairgrove , Nitin Gupta , David Nellans , Zi Yan Subject: [RFC PATCH 11/31] mm: debug: print compound page order in dump_page(). Date: Fri, 15 Feb 2019 14:08:36 -0800 Message-Id: <20190215220856.29749-12-zi.yan@sent.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190215220856.29749-1-zi.yan@sent.com> References: <20190215220856.29749-1-zi.yan@sent.com> Reply-To: ziy@nvidia.com MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Zi Yan Since we have more than just PMD-level THPs, printing compound page order is helpful to check the actual compound page sizes. Signed-off-by: Zi Yan --- mm/debug.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mm/debug.c b/mm/debug.c index 0abb987dad9b..21d211d7776c 100644 --- a/mm/debug.c +++ b/mm/debug.c @@ -68,8 +68,12 @@ void __dump_page(struct page *page, const char *reason) pr_warn("page:%px count:%d mapcount:%d mapping:%px index:%#lx", page, page_ref_count(page), mapcount, page->mapping, page_to_pgoff(page)); - if (PageCompound(page)) - pr_cont(" compound_mapcount: %d", compound_mapcount(page)); + if (PageCompound(page)) { + struct page *head = compound_head(page); + + pr_cont(" compound_mapcount: %d, order: %d", compound_mapcount(page), + compound_order(head)); + } pr_cont("\n"); if (PageAnon(page)) pr_warn("anon "); -- 2.20.1