From patchwork Mon Oct 4 06:13:25 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Naoya Horiguchi X-Patchwork-Id: 12533217 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 70036C433F5 for ; Mon, 4 Oct 2021 06:14:05 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 24A446136F for ; Mon, 4 Oct 2021 06:14:05 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 24A446136F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.dev Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id B73C2940009; Mon, 4 Oct 2021 02:14:04 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id AFD06940007; Mon, 4 Oct 2021 02:14:04 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 9ECFE940009; Mon, 4 Oct 2021 02:14:04 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0186.hostedemail.com [216.40.44.186]) by kanga.kvack.org (Postfix) with ESMTP id 9062B940007 for ; Mon, 4 Oct 2021 02:14:04 -0400 (EDT) Received: from smtpin10.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 4FA291801323F for ; Mon, 4 Oct 2021 06:14:04 +0000 (UTC) X-FDA: 78657739608.10.6265C6D Received: from out0.migadu.com (out0.migadu.com [94.23.1.103]) by imf28.hostedemail.com (Postfix) with ESMTP id E8F0F9001861 for ; Mon, 4 Oct 2021 06:14:03 +0000 (UTC) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1633328042; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=PdlL5nxCjGeUtk7PBO7npyqMWSmseCHKCkKUjUjDJbk=; b=gvBJ0tPHYr5GmsmevFSd4WHLsLMmdjXTjN/iRiRtpYBT1efX+/kUG1+PPe4+UsxVe/ICpI erz2XydsPouAPpx9r3ZJT5Ur2fBknQ3M3FncDI1jb0BHr5ewrrmHlz1933UZdXsYS9pGU0 GdvD7JKTozaF/4rYn7haVISxRrfOdTQ= From: Naoya Horiguchi To: linux-mm@kvack.org Cc: Andrew Morton , Konstantin Khlebnikov , Christian Hansen , Changbin Du , Bin Wang , Naoya Horiguchi , linux-kernel@vger.kernel.org Subject: [PATCH v1 3/3] tools/vm/page-types.c: print file offset in hexadecimal Date: Mon, 4 Oct 2021 15:13:25 +0900 Message-Id: <20211004061325.1525902-4-naoya.horiguchi@linux.dev> In-Reply-To: <20211004061325.1525902-1-naoya.horiguchi@linux.dev> References: <20211004061325.1525902-1-naoya.horiguchi@linux.dev> MIME-Version: 1.0 X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: naoya.horiguchi@linux.dev X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: E8F0F9001861 X-Stat-Signature: 5xyspfuo7trsuae118x1oafzbty6xmif Authentication-Results: imf28.hostedemail.com; dkim=pass header.d=linux.dev header.s=key1 header.b=gvBJ0tPH; dmarc=pass (policy=none) header.from=linux.dev; spf=pass (imf28.hostedemail.com: domain of naoya.horiguchi@linux.dev designates 94.23.1.103 as permitted sender) smtp.mailfrom=naoya.horiguchi@linux.dev X-HE-Tag: 1633328043-320417 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: From: Naoya Horiguchi In page list mode (with -l and -L option), virtual address and physical address are printed in hexadecimal, but file offset is not, which is confusing, so let's align it. Signed-off-by: Naoya Horiguchi --- tools/vm/page-types.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git v5.15-rc3/tools/vm/page-types.c v5.15-rc3_patched/tools/vm/page-types.c index fdb1891faf90..b1ed76d9a979 100644 --- v5.15-rc3/tools/vm/page-types.c +++ v5.15-rc3_patched/tools/vm/page-types.c @@ -390,7 +390,7 @@ static void show_page_range(unsigned long voffset, unsigned long offset, if (opt_pid) printf("%lx\t", voff); if (opt_file) - printf("%lu\t", voff); + printf("%lx\t", voff); if (opt_list_cgroup) printf("@%llu\t", (unsigned long long)cgroup0); if (opt_list_mapcnt) @@ -418,7 +418,7 @@ static void show_page(unsigned long voffset, unsigned long offset, if (opt_pid) printf("%lx\t", voffset); if (opt_file) - printf("%lu\t", voffset); + printf("%lx\t", voffset); if (opt_list_cgroup) printf("@%llu\t", (unsigned long long)cgroup); if (opt_list_mapcnt)