From: "Ricardo B. Marlière" <rbm@suse.com>
To: Shuah Khan <shuah@kernel.org>, Christian Brauner <brauner@kernel.org>
Cc: linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org,
"Ricardo B. Marliere" <rbm@suse.com>
Subject: [PATCH 0/3] selftests/namespaces: Fix test hangs and false failures
Date: Tue, 07 Apr 2026 11:35:44 -0300 [thread overview]
Message-ID: <20260407-selftests-namespaces_fixes-v1-0-59109909d88b@suse.com> (raw)
This series addresses three reliability problems in the namespaces selftest
suite that cause tests to hang or report incorrect results.
The first patch fixes a hang in nsid_test where the grandchild process is
not reaped during fixture teardown, leaving it alive and holding the TAP
pipe write-end open so the test runner blocks indefinitely waiting for EOF.
The second and third patches fix two problems in listns_efault_test: a
waitpid(-1) race that can cause the iterator child to be consumed during
namespace cleanup (leading to an indefinite block on the subsequent targeted
waitpid), and a false FAIL verdict on kernels that do not implement listns()
(the EFAULT tests should SKIP in that case, consistent with every other
listns test that already handles ENOSYS correctly).
Assisted-by: Claude Sonnet 4.6
Signed-off-by: Ricardo B. Marliere <rbm@suse.com>
---
Ricardo B. Marlière (3):
selftests/namespaces: Kill grandchild in nsid fixture teardown
selftests/namespaces: Fix waitpid race in listns_efault_test cleanup
selftests/namespaces: Skip efault tests when listns() is not available
.../selftests/namespaces/listns_efault_test.c | 33 ++++++++++++++++++----
tools/testing/selftests/namespaces/nsid_test.c | 14 ++++++++-
2 files changed, 40 insertions(+), 7 deletions(-)
---
base-commit: bfe62a454542cfad3379f6ef5680b125f41e20f4
change-id: 20260407-selftests-namespaces_fixes-43ff47179e5c
Best regards,
--
Ricardo B. Marlière <rbm@suse.com>
next reply other threads:[~2026-04-07 14:35 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-07 14:35 Ricardo B. Marlière [this message]
2026-04-07 14:35 ` [PATCH 1/3] selftests/namespaces: Kill grandchild in nsid fixture teardown Ricardo B. Marlière
2026-04-07 14:35 ` [PATCH 2/3] selftests/namespaces: Fix waitpid race in listns_efault_test cleanup Ricardo B. Marlière
2026-04-07 14:35 ` [PATCH 3/3] selftests/namespaces: Skip efault tests when listns() is not available Ricardo B. Marlière
2026-04-09 13:06 ` [PATCH 0/3] selftests/namespaces: Fix test hangs and false failures Christian Brauner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260407-selftests-namespaces_fixes-v1-0-59109909d88b@suse.com \
--to=rbm@suse.com \
--cc=brauner@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®