include/linux/damon.h | 29 ++++- mm/damon/core.c | 4 + mm/damon/sysfs-schemes.c | 253 ++++++++++++++++++++++++++++++++++++++- 3 files changed, 282 insertions(+), 4 deletions(-)
DAMOS_MIGRATE_{HOT,COLD} action can migrate pages to only single node. It could be useful to allow it migrates pages to multiple nodes with different weights. A work for dynamic interleaving[1] is in progress. We also discussed this could be useful for memory tiering, e.g., when we want to move pages to multiple noes of same tier. Extend the API and ABI interface for specifying the multiple destination nodes and their weights. Note that this RFC is a prototype of the interface change for Bijan's interleaving work[1]. Hence this patch series is only implementing the interface part, not the real implementation of the migration behavior. [1] https://lore.kernel.org/20250620180458.5041-1-bijan311@gmail.com [2] https://lore.kernel.org/20240408175228.91414-1-sj@kernel.org SeongJae Park (4): mm/damon: add struct damos_migrate_dest mm/damon/core: add damos->migrate_dest field mm/damon/sysfs-schemes: implement DAMOS action destinations directory mm/damon/sysfs-schemes: set damos->migrate_dest include/linux/damon.h | 29 ++++- mm/damon/core.c | 4 + mm/damon/sysfs-schemes.c | 253 ++++++++++++++++++++++++++++++++++++++- 3 files changed, 282 insertions(+), 4 deletions(-) base-commit: 78745efafbb93197e476717385616ed57ea2df22 -- 2.39.5
On Sat, 21 Jun 2025 10:31:27 -0700 SeongJae Park <sj@kernel.org> wrote: > DAMOS_MIGRATE_{HOT,COLD} action can migrate pages to only single node. > It could be useful to allow it migrates pages to multiple nodes with > different weights. A work for dynamic interleaving[1] is in progress. > We also discussed this could be useful for memory tiering, e.g., when we > want to move pages to multiple noes of same tier. > > Extend the API and ABI interface for specifying the multiple destination > nodes and their weights. > > Note that this RFC is a prototype of the interface change for Bijan's > interleaving work[1]. Hence this patch series is only implementing the > interface part, not the real implementation of the migration behavior. > > [1] https://lore.kernel.org/20250620180458.5041-1-bijan311@gmail.com > [2] https://lore.kernel.org/20240408175228.91414-1-sj@kernel.org > > SeongJae Park (4): > mm/damon: add struct damos_migrate_dest > mm/damon/core: add damos->migrate_dest field > mm/damon/sysfs-schemes: implement DAMOS action destinations directory > mm/damon/sysfs-schemes: set damos->migrate_dest > > include/linux/damon.h | 29 ++++- > mm/damon/core.c | 4 + > mm/damon/sysfs-schemes.c | 253 ++++++++++++++++++++++++++++++++++++++- > 3 files changed, 282 insertions(+), 4 deletions(-) > > > base-commit: 78745efafbb93197e476717385616ed57ea2df22 > -- > 2.39.5 Hi SeongJae, Thanks for putting this patch together. Sorry for taking a while to respond to it. I am finishing up V3 of the interleave patchset using these patches. It has mostly worked great, but I noticed that damos->migrate_dest was not being updated in damos_commit(), so new weights would not be applied. This meant that you could not update the interleave weights by committing the damon state. I also saw that damos->target_nid was also not being updated here. I will will have a patch fixing this with the V3 of the interleave patchset that I will hopefully send out tomorrow. Thanks, Bijan
On Tue, 1 Jul 2025 17:39:37 -0500 Bijan Tabatabai <bijan311@gmail.com> wrote: > On Sat, 21 Jun 2025 10:31:27 -0700 SeongJae Park <sj@kernel.org> wrote: > > > DAMOS_MIGRATE_{HOT,COLD} action can migrate pages to only single node. > > It could be useful to allow it migrates pages to multiple nodes with > > different weights. A work for dynamic interleaving[1] is in progress. > > We also discussed this could be useful for memory tiering, e.g., when we > > want to move pages to multiple noes of same tier. > > > > Extend the API and ABI interface for specifying the multiple destination > > nodes and their weights. > > > > Note that this RFC is a prototype of the interface change for Bijan's > > interleaving work[1]. Hence this patch series is only implementing the > > interface part, not the real implementation of the migration behavior. > > > > [1] https://lore.kernel.org/20250620180458.5041-1-bijan311@gmail.com > > [2] https://lore.kernel.org/20240408175228.91414-1-sj@kernel.org > > > > SeongJae Park (4): > > mm/damon: add struct damos_migrate_dest > > mm/damon/core: add damos->migrate_dest field > > mm/damon/sysfs-schemes: implement DAMOS action destinations directory > > mm/damon/sysfs-schemes: set damos->migrate_dest > > > > include/linux/damon.h | 29 ++++- > > mm/damon/core.c | 4 + > > mm/damon/sysfs-schemes.c | 253 ++++++++++++++++++++++++++++++++++++++- > > 3 files changed, 282 insertions(+), 4 deletions(-) > > > > > > base-commit: 78745efafbb93197e476717385616ed57ea2df22 > > -- > > 2.39.5 > > Hi SeongJae, > > Thanks for putting this patch together. Sorry for taking a while to > respond to it. No worry! > > I am finishing up V3 of the interleave patchset using these patches. It > has mostly worked great, but I noticed that damos->migrate_dest was not > being updated in damos_commit(), so new weights would not be applied. This > meant that you could not update the interleave weights by committing the > damon state. I also saw that damos->target_nid was also not being updated > here. I will will have a patch fixing Nice catch, thank you for finding the bug and making the fix! > this with the V3 of the interleave > patchset that I will hopefully send out tomorrow. I cannot wait, but please take your time! :) Thanks, SJ [...]
On Tue, 1 Jul 2025 17:23:16 -0700 SeongJae Park <sj@kernel.org> wrote: > On Tue, 1 Jul 2025 17:39:37 -0500 Bijan Tabatabai <bijan311@gmail.com> wrote: > > > On Sat, 21 Jun 2025 10:31:27 -0700 SeongJae Park <sj@kernel.org> wrote: [...] > > I am finishing up V3 of the interleave patchset using these patches. It > > has mostly worked great, but I noticed that damos->migrate_dest was not > > being updated in damos_commit(), so new weights would not be applied. This > > meant that you could not update the interleave weights by committing the > > damon state. I also saw that damos->target_nid was also not being updated > > here. I will will have a patch fixing > > Nice catch, thank you for finding the bug and making the fix! > > > this with the V3 of the interleave > > patchset that I will hopefully send out tomorrow. > > I cannot wait, but please take your time! :) I just realized this series is missing documentation updates. So I just posted[1] RFC v2 of this series with two documentation update patches and trivial commit messages wordsmithing. Note that other parts are same to RFC v1, including the damos_commit() bug and damos_migrate_dest name. Please pick the version to your v3 of interleave patch series if possible. [1] https://lore.kernel.org/20250702051558.54138-1-sj@kernel.org Thanks, SJ [...]
© 2016 - 2025 Red Hat, Inc.