From: Jan Polensky <japo@linux.ibm.com>
To: chrubis@suse.cz, pvorel@suse.cz
Cc: Linux Test Project <ltp@lists.linux.it>
Subject: [LTP] [PATCH v1 1/1] ioctl_pidfd06: expect EREMOTE for PIDFD_GET_INFO across pidns
Date: Wed, 18 Feb 2026 20:02:30 +0100 [thread overview]
Message-ID: <20260218190230.53759-1-japo@linux.ibm.com> (raw)
Kernel changed PIDFD_GET_INFO semantics when the pidfd refers to a task
that has no PID in the caller's current pid namespace: return -EREMOTE
instead of -ESRCH, allowing userspace to distinguish “different pidns”
from “process exited”.
Update ioctl_pidfd06 to expect EREMOTE in that case.
Link: https://www.spinics.net/lists/linux-fsdevel/msg326699.html
Link: https://lkml.org/lkml/2026/2/16/608
Link: https://lore.kernel.org/r/20260214010245.3671907-34-sashal@kernel.org
Signed-off-by: Jan Polensky <japo@linux.ibm.com>
---
testcases/kernel/syscalls/ioctl/ioctl_pidfd06.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/testcases/kernel/syscalls/ioctl/ioctl_pidfd06.c b/testcases/kernel/syscalls/ioctl/ioctl_pidfd06.c
index 751281bacb74..81205afb72a6 100644
--- a/testcases/kernel/syscalls/ioctl/ioctl_pidfd06.c
+++ b/testcases/kernel/syscalls/ioctl/ioctl_pidfd06.c
@@ -41,7 +41,7 @@ static void run(void)
args->exit_signal = SIGCHLD;
if (!SAFE_CLONE(args)) {
- TST_EXP_FAIL(ioctl(pidfd, PIDFD_GET_INFO, info), ESRCH);
+ TST_EXP_FAIL(ioctl(pidfd, PIDFD_GET_INFO, info), EREMOTE);
exit(0);
}
--
2.53.0
--
Mailing list info: https://lists.linux.it/listinfo/ltp
next reply other threads:[~2026-02-18 19:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-18 19:02 Jan Polensky [this message]
2026-02-19 8:19 ` [LTP] [PATCH v1 1/1] ioctl_pidfd06: expect EREMOTE for PIDFD_GET_INFO across pidns Petr Vorel
2026-02-19 8:49 ` Andrea Cervesato via ltp
2026-02-19 15:59 ` Jan Polensky
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=20260218190230.53759-1-japo@linux.ibm.com \
--to=japo@linux.ibm.com \
--cc=chrubis@suse.cz \
--cc=ltp@lists.linux.it \
--cc=pvorel@suse.cz \
/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