linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Audra Mitchell <audra@redhat.com>
To: linux-mm@kvack.org
Cc: raquini@redhat.com, akpm@linux-foundation.org, djakov@kernel.org,
	vbabka@suse.cz, linux-kernel@vger.kernel.org
Subject: [PATCH 1/5] mm/page_owner: Remove free_ts from page_owner output
Date: Fri, 13 Oct 2023 15:03:45 -0400	[thread overview]
Message-ID: <20231013190350.579407-2-audra@redhat.com> (raw)
In-Reply-To: <20231013190350.579407-1-audra@redhat.com>

When printing page_owner data via the sysfs interface, no free pages will
ever be dumped due to the series of checks in read_page_owner():

    /*
     * Although we do have the info about past allocation of free
     * pages, it's not relevant for current memory usage.
     */
     if (!test_bit(PAGE_EXT_OWNER_ALLOCATED, &page_ext->flags))

The free_ts values are still used when dump_page_owner() is called, so
keeping the field for other use cases but removing them for the typical
page_owner case.

Fixes: 866b48526217 ("mm/page_owner: record the timestamp of all pages during free")
Signed-off-by: Audra Mitchell <audra@redhat.com>
---
 mm/page_owner.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/page_owner.c b/mm/page_owner.c
index 4e2723e1b300..4f13ce7d2452 100644
--- a/mm/page_owner.c
+++ b/mm/page_owner.c
@@ -408,11 +408,11 @@ print_page_owner(char __user *buf, size_t count, unsigned long pfn,
 		return -ENOMEM;
 
 	ret = scnprintf(kbuf, count,
-			"Page allocated via order %u, mask %#x(%pGg), pid %d, tgid %d (%s), ts %llu ns, free_ts %llu ns\n",
+			"Page allocated via order %u, mask %#x(%pGg), pid %d, tgid %d (%s), ts %llu ns\n",
 			page_owner->order, page_owner->gfp_mask,
 			&page_owner->gfp_mask, page_owner->pid,
 			page_owner->tgid, page_owner->comm,
-			page_owner->ts_nsec, page_owner->free_ts_nsec);
+			page_owner->ts_nsec);
 
 	/* Print information relevant to grouping pages by mobility */
 	pageblock_mt = get_pageblock_migratetype(page);
-- 
2.41.0



  reply	other threads:[~2023-10-13 19:05 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-13 19:03 [PATCH 0/5] Fix page_owner's use of free timestamps Audra Mitchell
2023-10-13 19:03 ` Audra Mitchell [this message]
2023-10-17  8:07   ` [PATCH 1/5] mm/page_owner: Remove free_ts from page_owner output Vlastimil Babka
2023-10-13 19:03 ` [PATCH 2/5] tools/mm: Remove references to free_ts from page_owner_sort Audra Mitchell
2023-10-17  8:10   ` Vlastimil Babka
2023-10-13 19:03 ` [PATCH 3/5] tools/mm: Filter out timestamps for correct collation Audra Mitchell
2023-10-17  8:12   ` Vlastimil Babka
2023-10-13 19:03 ` [PATCH 4/5] tools/mm: Fix the default case for page_owner_sort Audra Mitchell
2023-10-17  8:13   ` Vlastimil Babka
2023-10-13 19:03 ` [PATCH 5/5] tools/mm: Update the usage output to be more organized Audra Mitchell
2023-10-17  8:13   ` Vlastimil Babka
2023-10-16 11:55 ` [PATCH 0/5] Fix page_owner's use of free timestamps Rafael Aquini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231013190350.579407-2-audra@redhat.com \
    --to=audra@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=djakov@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=raquini@redhat.com \
    --cc=vbabka@suse.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox