selftests: damon: add config file
Subsystems (3)
PATCH 1/2 selftests: damon: add config file
Building and running the subsuite 'damon' of kselftest, shows the following issues:
selftests: damon: debugfs_attrs.sh
/sys/kernel/debug/damon not found
By creating a config file enabling DAMON fragments in the selftests/damon/ directory the tests pass.
--- tools/testing/selftests/damon/config | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 tools/testing/selftests/damon/config
tools/testing/selftests/damon/config new file +8 -0
@@ -0,0 +1,8 @@ +CONFIG_DEBUG_SYSFS=y +CONFIG_DAMON=y +CONFIG_DAMON_SYSFS=y +CONFIG_DAMON_DBGFS=y +CONFIG_DAMON_PADDR=y +CONFIG_DAMON_VADDR=y +CONFIG_DAMON_RECLAIM=y +CONFIG_DAMON_LRU_SORT=y
Signature · 1 line
2.39.1
PATCH 2/2 selftests: damon: change scripts to be executable
When running kselftest-damon The following issues shows up:
'# Warning: file debugfs_attrs.sh is not executable'
Changing the scripts so they are executable.
--- tools/testing/selftests/damon/_chk_dependency.sh | 0 tools/testing/selftests/damon/_debugfs_common.sh | 0 tools/testing/selftests/damon/debugfs_attrs.sh | 0 .../testing/selftests/damon/debugfs_duplicate_context_creation.sh | 0 tools/testing/selftests/damon/debugfs_empty_targets.sh | 0 tools/testing/selftests/damon/debugfs_huge_count_read_write.sh | 0 tools/testing/selftests/damon/debugfs_rm_non_contexts.sh | 0 tools/testing/selftests/damon/debugfs_schemes.sh | 0 tools/testing/selftests/damon/debugfs_target_ids.sh | 0 tools/testing/selftests/damon/lru_sort.sh | 0 tools/testing/selftests/damon/reclaim.sh | 0 tools/testing/selftests/damon/sysfs.sh | 0 tools/testing/selftests/damon/sysfs_update_removed_scheme_dir.sh | 0 13 files changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 tools/testing/selftests/damon/_chk_dependency.sh mode change 100644 => 100755 tools/testing/selftests/damon/_debugfs_common.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_attrs.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_duplicate_context_creation.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_empty_targets.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_huge_count_read_write.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_rm_non_contexts.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_schemes.sh mode change 100644 => 100755 tools/testing/selftests/damon/debugfs_target_ids.sh mode change 100644 => 100755 tools/testing/selftests/damon/lru_sort.sh mode change 100644 => 100755 tools/testing/selftests/damon/reclaim.sh mode change 100644 => 100755 tools/testing/selftests/damon/sysfs.sh mode change 100644 => 100755 tools/testing/selftests/damon/sysfs_update_removed_scheme_dir.sh
tools/testing/selftests/damon/_chk_dependency.sh +0 -0
tools/testing/selftests/damon/_debugfs_common.sh +0 -0
tools/testing/selftests/damon/debugfs_attrs.sh +0 -0
tools/testing/selftests/damon/debugfs_duplicate_context_creation.sh +0 -0
tools/testing/selftests/damon/debugfs_empty_targets.sh +0 -0
tools/testing/selftests/damon/debugfs_huge_count_read_write.sh +0 -0
tools/testing/selftests/damon/debugfs_rm_non_contexts.sh +0 -0
tools/testing/selftests/damon/debugfs_schemes.sh +0 -0
tools/testing/selftests/damon/debugfs_target_ids.sh +0 -0
tools/testing/selftests/damon/lru_sort.sh +0 -0
tools/testing/selftests/damon/reclaim.sh +0 -0
tools/testing/selftests/damon/sysfs.sh +0 -0
tools/testing/selftests/damon/sysfs_update_removed_scheme_dir.sh +0 -0
Signature · 1 line
2.39.1
SeongJae Park
maintainerRe: [PATCH 2/2] selftests: damon: change scripts to be executable
Quoted 5 lines · On Tue, 21 Feb 2023 08:08:37 +0100 Anders Roxell <[email protected]>…
When running kselftest-damon The following issues shows up:
'# Warning: file
debugfs_attrs.shis not executable'Changing the scripts so they are executable.
I tried to make similar changes before[1], but resulted in making a change in kselftest following Greg's comment[2]. So it might make sense to remove the warning message from kselftest instead of this change, though I think this change also looks good. Could I ask others' opinions?
[1] https://lore.kernel.org/mm-commits/[email protected]/
[2] https://lore.kernel.org/mm-commits/[email protected]/
Thanks,
SJ
Quoted 3 lines
Signed-off-by Anders Roxell <[email protected]>---
SeongJae Park
maintainerHi Anders,
Thank you for this patch!
Quoted 8 lines · On Tue, 21 Feb 2023 08:08:36 +0100 Anders Roxell <[email protected]>…
Building and running the subsuite 'damon' of kselftest, shows the following issues:
selftests: damon:debugfs_attrs.sh
/sys/kernel/debug/damonnot foundBy creating a config file enabling DAMON fragments in the selftests/damon/ directory the tests pass.
I think we could put Fixes tag as below?
Though this may not need to be merged in stable.
Quoted 13 lines
Reported-by Naresh Kamboju <[email protected]>Signed-off-by Anders Roxell <[email protected]>--- tools/testing/selftests/damon/config | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 tools/testing/selftests/damon/configtools/testing/selftests/damon/config new file +0
-0
tools/testing/selftests/damon/config line 1
Quoted 1 line
tools/testing/selftests/damon/config new file +1
-0@@ -0,0 +1,8 @@ +CONFIG_DEBUG_SYSFS=y
's/SYS//'? Or, I guess this is not needed at all?
tools/testing/selftests/damon/config line 8
Quoted 7 lines
tools/testing/selftests/damon/config new file +7
-0+CONFIG_DAMON=y +CONFIG_DAMON_SYSFS=y +CONFIG_DAMON_DBGFS=y +CONFIG_DAMON_PADDR=y +CONFIG_DAMON_VADDR=y +CONFIG_DAMON_RECLAIM=y +CONFIG_DAMON_LRU_SORT=y
Thanks,
SJ
Quoted 2 lines
Signature · 1 line
2.39.1
Quoted 13 lines · SeongJae Park
Hi Anders,
Thank you for this patch!
Quoted 5 lines · On Tue, 21 Feb 2023 08:08:36 +0100 Anders Roxell <[email protected]>…
Building and running the subsuite 'damon' of kselftest, shows the following issues:
selftests: damon:debugfs_attrs.sh
/sys/kernel/debug/damonnot found
Quoted 7 lines
Quoted 3 lines
By creating a config file enabling DAMON fragments in the selftests/damon/ directory the tests pass.
I think we could put Fixes tag as below?
Fixes b348eb7abd09 ("mm/damon: add user space selftests")
Make sense, I'll add it.
Quoted 10 lines
Though this may not need to be merged in stable.
Quoted 7 lines
Reported-by Naresh Kamboju <[email protected]>Signed-off-by Anders Roxell <[email protected]>--- tools/testing/selftests/damon/config | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 tools/testing/selftests/damon/config
Quoted 9 lines
tools/testing/selftests/damon/config line 1
Quoted 7 lines
tools/testing/selftests/damon/config new file +1
-0@@ -0,0 +1,8 @@ +CONFIG_DEBUG_SYSFS=y's/SYS//'? Or, I guess this is not needed at all?
This can be dropped.
Thank you.
I'll respin the patch shortly.
Cheers,
Anders
Quoted 15 lines
tools/testing/selftests/damon/config line 8
Quoted 8 lines
tools/testing/selftests/damon/config new file +7
-0+CONFIG_DAMON=y +CONFIG_DAMON_SYSFS=y +CONFIG_DAMON_DBGFS=y +CONFIG_DAMON_PADDR=y +CONFIG_DAMON_VADDR=y +CONFIG_DAMON_RECLAIM=y +CONFIG_DAMON_LRU_SORT=yThanks,
SJQuoted 2 lines
--
2.39.1