From mboxrd@z Thu Jan 1 00:00:00 1970 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.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 EF4C3C433E6 for ; Tue, 9 Feb 2021 12:41:12 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 7888C64E50 for ; Tue, 9 Feb 2021 12:41:12 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7888C64E50 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 8BEDA6B0005; Tue, 9 Feb 2021 07:41:11 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 86F116B006C; Tue, 9 Feb 2021 07:41:11 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 7375E6B006E; Tue, 9 Feb 2021 07:41:11 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0237.hostedemail.com [216.40.44.237]) by kanga.kvack.org (Postfix) with ESMTP id 5E4D06B0005 for ; Tue, 9 Feb 2021 07:41:11 -0500 (EST) Received: from smtpin27.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id 25B94363C for ; Tue, 9 Feb 2021 12:41:11 +0000 (UTC) X-FDA: 77798689542.27.color30_550a2c327607 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin27.hostedemail.com (Postfix) with ESMTP id F1DD03D663 for ; Tue, 9 Feb 2021 12:41:10 +0000 (UTC) X-HE-Tag: color30_550a2c327607 X-Filterd-Recvd-Size: 4157 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by imf29.hostedemail.com (Postfix) with ESMTP for ; Tue, 9 Feb 2021 12:41:09 +0000 (UTC) IronPort-SDR: dkhNDnZCHEWTN3B3Ptf3k5zAgRtGpQO/DF33d6CQC7tH2HViKGrdX8yMOlDosFhCMfUjfI9XG1 h0U8IljRQBxQ== X-IronPort-AV: E=McAfee;i="6000,8403,9889"; a="179313668" X-IronPort-AV: E=Sophos;i="5.81,164,1610438400"; d="scan'208";a="179313668" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Feb 2021 04:41:08 -0800 IronPort-SDR: 6KPKfSvEZSTkUrzHjcp/yuliol8zzke1i7JlRE/MWmabiN1Rfs7TsNnoJ4kMBS/hCoUtpjfX8N Kp/n0M/KEWgQ== X-IronPort-AV: E=Sophos;i="5.81,164,1610438400"; d="scan'208";a="398768358" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Feb 2021 04:41:04 -0800 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1l9SKD-003DWG-9k; Tue, 09 Feb 2021 14:41:01 +0200 Date: Tue, 9 Feb 2021 14:41:01 +0200 From: Andy Shevchenko To: Yafang Shao Cc: willy@infradead.org, david@redhat.com, linmiaohe@huawei.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, joe@perches.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4 0/3] mm, vsprintf: dump full information of page flags in pGp Message-ID: References: <20210209105613.42747-1-laoar.shao@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210209105613.42747-1-laoar.shao@gmail.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo 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: On Tue, Feb 09, 2021 at 06:56:10PM +0800, Yafang Shao wrote: > The existed pGp shows the names of page flags only, rather than the full > information including section, node, zone, last cpuipid and kasan tag. > While it is not easy to parse these information manually because there > are so many flavors. We'd better interpret them in printf. > > To be compitable with the existed format of pGp, the new introduced ones > also use '|' as the separator, then the user tools parsing pGp won't > need to make change, suggested by Matthew. The new added information is > tracked onto the end of the existed one, e.g. > [ 8838.835456] Slab 0x000000002828b78a objects=33 used=3 fp=0x00000000d04efc88 flags=0x17ffffc0010200(slab|head|node=0|zone=2|lastcpupid=0x1fffff) > > The documentation and test cases are also updated. The result of the > test cases as follows, > [ 501.485081] test_printf: loaded. > [ 501.485768] test_printf: all 388 tests passed > [ 501.488762] test_printf: unloaded. > > This patchset also includes some code cleanup in mm/slub.c. FWIW, Reviewed-by: Andy Shevchenko > v4: > - extend %pGp instead of introducing new format, per Matthew > > v3: > - coding improvement, per Joe and Andy > - the possible impact on debugfs and the fix of it, per Joe and Matthew > - introduce new format instead of changing pGp, per Andy > > v2: > - various coding improvement, per Joe, Miaohe, Vlastimil and Andy > - remove the prefix completely in patch #2, per Vlastimil > - Update the test cases, per Andy > > Yafang Shao (3): > mm, slub: use pGp to print page flags > mm, slub: don't combine pr_err with INFO > vsprintf: dump full information of page flags in pGp > > Documentation/core-api/printk-formats.rst | 2 +- > lib/test_printf.c | 60 +++++++++++++++++---- > lib/vsprintf.c | 66 +++++++++++++++++++++-- > mm/slub.c | 13 ++--- > 4 files changed, 121 insertions(+), 20 deletions(-) > > -- > 2.17.1 > -- With Best Regards, Andy Shevchenko