Skip to contentSkip to conversation

selftests/damon: fix selftests by installing drgn related script

PATCH Applied Sang-Heon Jeon 3 participants 6 messages Aug 12, 2025 – Aug 13, 2025

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 selftests/damon: fix selftests by installing drgn related script

drgn_dump_damon_status is not installed while kselftest setup. It can breaks other tests which depend on drgn_dump_damon_status. Install drgn_dump_damon_status files to fix broken test.

---
While setup kselftest executable environment and test this patch [1], I found similiar issue. Honestly, I don't know exact solution for this situation. So I just make a new patch. Sorry if it is wrong direction, then please let me know how to do next.

[1] https://lore.kernel.org/damon/[email protected]/

---
 tools/testing/selftests/damon/Makefile | 1 +
 1 file changed, 1 insertion(+)
tools/testing/selftests/damon/Makefile +1 -0
index 44a4a819df55..029de547f31c 100644
@@ -4,6 +4,7 @@
 TEST_GEN_FILES += access_memory access_memory_even
 
 TEST_FILES = _damon_sysfs.py
+TEST_FILES += drgn_dump_damon_status.py
 
 # functionality tests
 TEST_PROGS += sysfs.sh
Signature · 1 line
2.43.0
maintainer Reviewed-by on v1 1/1
#1 lore raw
Quoted 3 lines · On Tue, 12 Aug 2025 23:00:46 +0900 Sang-Heon Jeon <[email protected]> wrote:

drgn_dump_damon_status is not installed while kselftest setup. It can breaks other tests which depend on drgn_dump_damon_status. Install drgn_dump_damon_status files to fix broken test.

This patch conflicts with the similar one from Alexandre Ghiti. Could you please rebase yours on top of Alexandre's one (and mention the dependency on the comment section under '---' line), unless Andrew resolves the conflict on his own?

Quoted 3 lines
Quoted 7 lines

---
While setup kselftest executable environment and test this patch [1], I found similiar issue. Honestly, I don't know exact solution for this situation. So I just make a new patch. Sorry if it is wrong direction, then please let me know how to do next.

[1] https://lore.kernel.org/damon/[email protected]/

For patches that you are not really confident about and hence not insisting to merge as-is, but wanna ask other's opinions first, you can ask questions via plain text mails, or post patches with RFC tag on the subject.

I think this is the right patch, though.

You could refer to the TEST_FILES part of documentation[1] and "Install selftests" section on the document for more details.

[1] https://origin.kernel.org/doc/html/latest/dev-tools/kselftest.html#contributing-new-tests-details

Thanks,
SJ

[...]

maintainer
#2 lore raw
Quoted 12 lines · On Tue, 12 Aug 2025 10:59:39 -0700 SeongJae Park <[email protected]> wrote:
Quoted 3 lines · On Tue, 12 Aug 2025 23:00:46 +0900 Sang-Heon Jeon <[email protected]> wrote:

drgn_dump_damon_status is not installed while kselftest setup. It can breaks other tests which depend on drgn_dump_damon_status. Install drgn_dump_damon_status files to fix broken test.

This patch conflicts with the similar one from Alexandre Ghiti. Could you please rebase yours on top of Alexandre's one (and mention the dependency on the comment section under '---' line), unless Andrew resolves the conflict on his own?

Quoted 1 line
Quoted 4 lines
Quoted 2 lines

I'll add

Fixes f3e8e1e51362 ("selftests/damon: add drgn script for extracting damon status")
#3 lore raw

Hello Andrew

Quoted 15 lines · Andrew Morton
Quoted 12 lines · On Tue, 12 Aug 2025 10:59:39 -0700 SeongJae Park <[email protected]> wrote:
Quoted 3 lines · On Tue, 12 Aug 2025 23:00:46 +0900 Sang-Heon Jeon <[email protected]> wrote:

drgn_dump_damon_status is not installed while kselftest setup. It can breaks other tests which depend on drgn_dump_damon_status. Install drgn_dump_damon_status files to fix broken test.

This patch conflicts with the similar one from Alexandre Ghiti. Could you please rebase yours on top of Alexandre's one (and mention the dependency on the comment section under '---' line), unless Andrew resolves the conflict on his own?

Quoted 1 line
Quoted 7 lines
Quoted 4 lines
Quoted 2 lines

I'll add

Fixes f3e8e1e51362 ("selftests/damon: add drgn script for extracting damon status")

Thank you for your help. I'll do better next time :)

Best Regards.
Sang-Heon Jeon

#4 lore raw
In reply to SeongJae Park

Hi SeongJae

Quoted 11 lines · SeongJae Park
Quoted 3 lines · On Tue, 12 Aug 2025 23:00:46 +0900 Sang-Heon Jeon <[email protected]> wrote:

drgn_dump_damon_status is not installed while kselftest setup. It can breaks other tests which depend on drgn_dump_damon_status. Install drgn_dump_damon_status files to fix broken test.

This patch conflicts with the similar one from Alexandre Ghiti. Could you please rebase yours on top of Alexandre's one (and mention the dependency on the comment section under '---' line), unless Andrew resolves the conflict on his own?

Oh, I didn't know that I can use the baseline with an unmerged patch. As your solution, I can avoid conflict (This time Andrew already did it) Thanks for letting me know. I'll keep that in my mind as well.

Quoted 12 lines
Quoted 3 lines
Quoted 6 lines

---
While setup kselftest executable environment and test this patch [1], I found similiar issue. Honestly, I don't know exact solution for this situation. So I just make a new patch. Sorry if it is wrong direction, then please let me know how to do next.

Quoted 5 lines
Quoted 1 line

[1] https://lore.kernel.org/damon/[email protected]/

For patches that you are not really confident about and hence not insisting to merge as-is, but wanna ask other's opinions first, you can ask questions via plain text mails, or post patches with RFC tag on the subject.

My meaning of "don't know exact solution" was about conflict patch (Now I read again, I think other people might be confused. That's you, sob) I will use the method mentioned above from now on. Anyway, thanks for reminding me about RFC.

Quoted 4 lines

I think this is the right patch, though.

You could refer to the TEST_FILES part of documentation[1] and "Install selftests" section on the document for more details.

Thank you for this comment too, and for your always kindness.

Quoted 7 lines

[1] https://origin.kernel.org/doc/html/latest/dev-tools/kselftest.html#contributing-new-tests-details

Thanks,
SJ

[...]

Best Regards.
Sang-Heon Jeon

maintainer
#5 lore raw
Quoted 5 lines · On Wed, 13 Aug 2025 11:24:27 +0900 Sang-Heon Jeon <[email protected]> wrote:

Hi SeongJae

Quoted 2 lines · SeongJae Park

On Tue, 12 Aug 2025 23:00:46 +0900 Sang-Heon Jeon <[email protected]> wrote:

[...]

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

While setup kselftest executable environment and test this patch [1], I found similiar issue. Honestly, I don't know exact solution for this situation. So I just make a new patch. Sorry if it is wrong direction, then please let me know how to do next.

Quoted 8 lines
Quoted 5 lines
Quoted 1 line

[1] https://lore.kernel.org/damon/[email protected]/

For patches that you are not really confident about and hence not insisting to merge as-is, but wanna ask other's opinions first, you can ask questions via plain text mails, or post patches with RFC tag on the subject.

My meaning of "don't know exact solution" was about conflict patch (Now I read again, I think other people might be confused.

Thank you for clarifying!

Quoted 2 lines

That's you,
sob) I will use the method mentioned above from now on.

In the case, another (and probably more common) approach would be sharing your finding of remaining bugs with the original patch author. Probably sharing that as a reply-to-all to the patch would be good. Then, the original author could revise and post the next version of the patch in a more complete form.

[...]

Quoted 1 line

Thank you for this comment too, and for your always kindness.

The pleasure is mine :)

Thanks,
SJ

[...]