The next step after executing the test is a wait, but there is nothing to wait for in the child, so just return. Signed-off-by: Usama Arif <usamaarif642@xxxxxxxxx> --- tools/testing/selftests/mm/prctl_thp_disable.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/mm/prctl_thp_disable.c b/tools/testing/selftests/mm/prctl_thp_disable.c index e9e519c85224c..df3cce278e10a 100644 --- a/tools/testing/selftests/mm/prctl_thp_disable.c +++ b/tools/testing/selftests/mm/prctl_thp_disable.c @@ -161,8 +161,10 @@ TEST_F(prctl_thp_disable_completely, fork) pid = fork(); ASSERT_GE(pid, 0); - if (!pid) + if (!pid) { prctl_thp_disable_completely_test(_metadata, self->pmdsize, variant->thp_policy); + return; + } wait(&ret); if (WIFEXITED(ret)) -- 2.47.3