From: "zhen.ni" <zhen.ni@easystack.cn>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: vbabka@kernel.org, surenb@google.com, mhocko@suse.com,
jackmanb@google.com, hannes@cmpxchg.org, ziy@nvidia.com,
linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Yichong Chen <chenyichong@uniontech.com>,
Ye Liu <ye.liu@linux.dev>
Subject: Re: [PATCH v11 0/4] mm/page_owner: add per-fd filter infrastructure for print_mode and NUMA filtering
Date: Thu, 25 Jun 2026 20:57:29 +0800 [thread overview]
Message-ID: <577bcce8-7cdf-4fea-b895-04fa5bda13ea@easystack.cn> (raw)
In-Reply-To: <20260624215526.ed20169b440c62d71a3f9d90@linux-foundation.org>
在 2026/6/25 12:55, Andrew Morton 写道:
> On Thu, 25 Jun 2026 12:30:57 +0800 Zhen Ni <zhen.ni@easystack.cn> wrote:
>
>> This patch series introduces per-file-descriptor filtering capabilities to the
>> page_owner feature.
>
> Well, I assume this work was inspired by your own operational
> experience with page_owner. There's no better inspiration than this!
>
> Review is thin (absent) at v11. This is typical with page_owner
> changes :(. I'll add the series for testing while interested people
> check over it (please).
>
> AI review might have found a few things which you might choose to
> address. Please check it out:
>
> https://sashiko.dev/#/patchset/20260625043101.338794-1-zhen.ni@easystack.cn
>
>
>
>
Hi,
Thanks for the review. Let me address the questions:
Q1: Can empty write silently revert concurrent filter changes?
Q3: Can concurrent writes clobber independent filter settings?
A1&3: Yes, this is theoretically possible when multiple threads share
the same fd. The current implementation uses short-duration spinlocks as
a practical trade-off rather than holding locks during the entire
parsing process.
However, I believe the current design meets functional requirements:
1. Most users will use the page_owner_filter tool rather than
programming against page_owner directly. For concurrent filtering needs,
multiple processes can use independent file descriptors.
2. Even in the multi-threaded shared-fd case, the worst outcome is that
filter settings get overwritten. Since page_owner is a debug feature,
the impact is limited.
---
Q2: How can users disable/clear the NUMA node filter?
A2: Clearing the NUMA filter while holding the fd open is an edge case
without strong practical necessity. If users need to change filter
behavior, they can simply:
- Apply a different filter in the next write operation, or
- Close and reopen the file descriptor
The filter is designed for targeted debugging sessions where the
configuration is set up front and used for the session.
If you believe that holding locks for the entire write process is
necessary, please let me know.
Thanks,
Zhen
next prev parent reply other threads:[~2026-06-25 12:57 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-25 4:30 [PATCH v11 0/4] mm/page_owner: add per-fd filter infrastructure for print_mode and NUMA filtering Zhen Ni
2026-06-25 4:30 ` [PATCH v11 1/4] mm/page_owner: add print_mode filter Zhen Ni
2026-06-25 18:26 ` Zi Yan
2026-06-25 19:20 ` Andrew Morton
2026-06-25 19:24 ` Zi Yan
2026-06-25 4:30 ` [PATCH v11 2/4] mm/page_owner: add NUMA node filter Zhen Ni
2026-06-25 18:37 ` Zi Yan
2026-06-25 19:27 ` Zi Yan
2026-06-25 20:04 ` Andrew Morton
2026-06-25 4:31 ` [PATCH v11 3/4] tools/mm: add page_owner_filter userspace tool Zhen Ni
2026-06-25 4:50 ` Andrew Morton
2026-06-25 4:31 ` [PATCH v11 4/4] mm/page_owner: document page_owner filter Zhen Ni
2026-06-25 4:55 ` [PATCH v11 0/4] mm/page_owner: add per-fd filter infrastructure for print_mode and NUMA filtering Andrew Morton
2026-06-25 12:57 ` zhen.ni [this message]
2026-06-25 18:22 ` Zi Yan
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=577bcce8-7cdf-4fea-b895-04fa5bda13ea@easystack.cn \
--to=zhen.ni@easystack.cn \
--cc=akpm@linux-foundation.org \
--cc=chenyichong@uniontech.com \
--cc=hannes@cmpxchg.org \
--cc=jackmanb@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mhocko@suse.com \
--cc=surenb@google.com \
--cc=vbabka@kernel.org \
--cc=ye.liu@linux.dev \
--cc=ziy@nvidia.com \
/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