[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20251017163021.116255-1-sj@kernel.org>
Date: Fri, 17 Oct 2025 09:30:19 -0700
From: SeongJae Park <sj@...nel.org>
To: Bijan Tabatabai <bijan311@...il.com>
Cc: SeongJae Park <sj@...nel.org>,
Andrew Morton <akpm@...ux-foundation.org>,
damon@...ts.linux.dev,
linux-kernel@...r.kernel.org,
linux-mm@...ck.org
Subject: Re: [RFC PATCH 1/5] mm/damon/core: add damon_target->obsolete for pin-point removal
On Fri, 17 Oct 2025 09:52:16 -0500 Bijan Tabatabai <bijan311@...il.com> wrote:
> Thanks for working on this SJ!
My pleasure!
>
> On Thu, Oct 16, 2025 at 4:47 PM SeongJae Park <sj@...nel.org> wrote:
> >
> > DAMON's monitoring targets parameters update function,
> > damon_commit_targets(), is not providing a way to remove a target in the
> > middle of existing targets list. Extend the API by adding a field to
> > struct damon_target. If the field of a damon_commit_targets() source
> > target is set, it indicates the matcing target on the existing targets
> > list is obsolete. damon_commit_targets() understands that and remove
> > those from the list, while respecting the index based matching for other
> > non-obsolete targets.
> >
> > Signed-off-by: SeongJae Park <sj@...nel.org>
> > ---
> > include/linux/damon.h | 6 ++++++
> > mm/damon/core.c | 10 +++++++++-
> > 2 files changed, 15 insertions(+), 1 deletion(-)
> >
> > diff --git a/include/linux/damon.h b/include/linux/damon.h
> > index 524dea87cac7..8a7b45b9e40d 100644
> > --- a/include/linux/damon.h
> > +++ b/include/linux/damon.h
> > @@ -92,17 +92,23 @@ struct damon_region {
> > * @nr_regions: Number of monitoring target regions of this target.
> > * @regions_list: Head of the monitoring target regions of this target.
> > * @list: List head for siblings.
> > + * @obsolete: Whether the commit destination target is obsolete.
> > *
> > * Each monitoring context could have multiple targets. For example, a context
> > * for virtual memory address spaces could have multiple target processes. The
> > * @pid should be set for appropriate &struct damon_operations including the
> > * virtual address spaces monitoring operations.
> > + *
> > + * @obsolte is used only for damon_commit_targets() source targets, to specify
> > + * the matching destination targets are obsolte. Read damon_commit_targets()
> > + * to see how it is handled.
> > */
> Nit: Twice in the above comment you've written "obsolte" instead of "obsolete."
Thank you for catching this, I will definitely fix those on the next spin.
>
> With that fixed
> Reviewed-by: Bijan Tabatabai <bijan311@...il.com>
> for the entire series.
Thank you!
Thanks,
SJ
[...]
Powered by blists - more mailing lists