From patchwork Thu Jan 28 02:19:45 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yafang Shao X-Patchwork-Id: 12051637 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DBB53C433E0 for ; Thu, 28 Jan 2021 02:20:20 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 0098164DCC for ; Thu, 28 Jan 2021 02:20:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0098164DCC Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 840A96B006C; Wed, 27 Jan 2021 21:20:19 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 7EF826B006E; Wed, 27 Jan 2021 21:20:19 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 708B66B0070; Wed, 27 Jan 2021 21:20:19 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0025.hostedemail.com [216.40.44.25]) by kanga.kvack.org (Postfix) with ESMTP id 5CE0D6B006C for ; Wed, 27 Jan 2021 21:20:19 -0500 (EST) Received: from smtpin25.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 219041EE6 for ; Thu, 28 Jan 2021 02:20:19 +0000 (UTC) X-FDA: 77753579358.25.mouth21_121027b2759c Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin25.hostedemail.com (Postfix) with ESMTP id EC4361804E3A1 for ; Thu, 28 Jan 2021 02:20:18 +0000 (UTC) X-HE-Tag: mouth21_121027b2759c X-Filterd-Recvd-Size: 4349 Received: from mail-oo1-f54.google.com (mail-oo1-f54.google.com [209.85.161.54]) by imf39.hostedemail.com (Postfix) with ESMTP for ; Thu, 28 Jan 2021 02:20:18 +0000 (UTC) Received: by mail-oo1-f54.google.com with SMTP id r199so1077340oor.2 for ; Wed, 27 Jan 2021 18:20:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zYH+mxvn2A3dJD0z4OcS09UkAKI7HiExMGSeLtKn4tM=; b=tiLdanme9ZPBFmKmUuqRLeH0jzl1towtFwyue+W036MJ4w7Q0h3Sm2QCo4P1rIaIlk 7D4SLMuAhkyYviCcoDpfvA0uOU8oaZTxj+tLUOr5WubWXhJ4SsIB0Ydz+Io8iLcPYytW ePgTpOJp/AbNutt5hSSVtiPIy5WrR2pb4kS5ZQ0451wXIFLnSWmApDHyVIAkKTcVWFQk POsFMp4eMdPSfwh4Vd2fRDnImdpCIULirez05hpHBCakb89KyHRO5WN6xhtZjQOKoUHA CX65q8qxcvc7z5zyn3y7QQHf3CDBv+f4wcbyD54+hg68pHuxvXdbbDwtSX4TyJrkDlrt 8QVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zYH+mxvn2A3dJD0z4OcS09UkAKI7HiExMGSeLtKn4tM=; b=StsK1194ns7AfTbgUfFrI36HVYnIa860O3Sr+RoLUzumnh7ml2dA1yldh2kgIDmMIb oKV4/RTAldmfM8gtsVYByTdUZXKc1jSWJUkaYKDvWAZ1+7I1L2N2zwroxmLuqthDRNSu Lu5j9+XviTBDUXwdnQpFUJsPN5XSwqE/qr9O7OIiWE/QJ3vX6fJOkTElmQfz7undd6Kp 7ZFPUeLZK+x01alVTxcWOBorO00cBedV4RAnYJPEMOhOE6uSLNhF1vaktVjb89p+Y2+m SlpJlr5bMaO8lEe7a9Nv7oCiI47riKJPDZ5ZYTCO1dwPhTJw6okRzxr7M5jt5JUrSSfB SjHw== X-Gm-Message-State: AOAM531y2I+dLJLnDNF4VcJV65T4Ty9V1HBakeBGzMSPwAi129gssH7d uKO8Ian0tECOxQixj8YRfC8= X-Google-Smtp-Source: ABdhPJwfIyMxrySXxF9sSW16i+roO96QXXqk46k4/giZAvfnNk8o1ICwull2rDWtQmj+ARrMwaG5kg== X-Received: by 2002:a4a:646:: with SMTP id 67mr9826383ooj.33.1611800417909; Wed, 27 Jan 2021 18:20:17 -0800 (PST) Received: from localhost.localdomain ([50.236.19.102]) by smtp.gmail.com with ESMTPSA id m10sm731246otp.19.2021.01.27.18.20.12 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jan 2021 18:20:17 -0800 (PST) From: Yafang Shao To: david@redhat.com, vbabka@suse.cz, cl@linux.com, penberg@kernel.org, rientjes@google.com, iamjoonsoo.kim@lge.com, akpm@linux-foundation.org, pmladek@suse.com, rostedt@goodmis.org, sergey.senozhatsky@gmail.com, andriy.shevchenko@linux.intel.com, linux@rasmusvillemoes.dk Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Yafang Shao Subject: [PATCH 1/3] mm, slub: use pGp to print page flags Date: Thu, 28 Jan 2021 10:19:45 +0800 Message-Id: <20210128021947.22877-2-laoar.shao@gmail.com> X-Mailer: git-send-email 2.24.3 (Apple Git-128) In-Reply-To: <20210128021947.22877-1-laoar.shao@gmail.com> References: <20210128021947.22877-1-laoar.shao@gmail.com> MIME-Version: 1.0 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: As pGp has been already introduced in printk, we'd better use it to make the output human readable. Before this change, the output is, [ 6155.716018] INFO: Slab 0x000000004027dd4f objects=33 used=3 fp=0x000000008cd1579c flags=0x17ffffc0010200 While after this change, the output is, [ 8846.517809] INFO: Slab 0x00000000f42a2c60 objects=33 used=3 fp=0x0000000060d32ca8 flags=0x17ffffc0010200(slab|head) Reviewed-by: David Hildenbrand Signed-off-by: Yafang Shao Reviewed-by: Vlastimil Babka Acked-by: David Rientjes --- mm/slub.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mm/slub.c b/mm/slub.c index 69742ab9a21d..4b9ab267afbc 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -641,8 +641,9 @@ void print_tracking(struct kmem_cache *s, void *object) static void print_page_info(struct page *page) { - pr_err("INFO: Slab 0x%p objects=%u used=%u fp=0x%p flags=0x%04lx\n", - page, page->objects, page->inuse, page->freelist, page->flags); + pr_err("INFO: Slab 0x%p objects=%u used=%u fp=0x%p flags=%#lx(%pGp)\n", + page, page->objects, page->inuse, page->freelist, + page->flags, &page->flags); }