NetBSD Problem Report #61005
From www@netbsd.org Sat Nov 14 03:43:23 2026
Return-Path: <www@netbsd.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature RSA-PSS (2048 bits)
client-signature RSA-PSS (2048 bits))
(Client CN "mail.netbsd.org", Issuer "YR1" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id 5D3B21A923B
for <gnats-bugs@gnats.NetBSD.org>; Sat, 14 Nov 2026 03:43:23 +0000 (UTC)
Message-Id: <20261114034322.374411A923C@mollari.NetBSD.org>
Date: Sat, 14 Nov 2026 03:43:22 +0000 (UTC)
From: koorogi@koorogi.info
Reply-To: koorogi@koorogi.info
To: gnats-bugs@NetBSD.org
Subject: compat_linux fails to set si_pid when delivering SI_QUEUE signal to Linux process
X-Send-Pr-Version: www-1.0
X-From4GNATS: "koorogi@koorogi.info via gnats" <gnats-admin@NetBSD.org>
>Number: 61005
>Category: kern
>Synopsis: compat_linux fails to set si_pid when delivering SI_QUEUE signal to Linux process
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: kern-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Nov 14 03:45:00 +0000 2026
>Last-Modified: Sun Nov 15 22:40:01 +0000 2026
>Originator: Bobby Bingham
>Release: NetBSD-current 20261111155711
>Organization:
>Environment:
NetBSD netbsdvm.local 11.99.11 NetBSD 11.99.11 (GENERIC) #0: Wed Nov 11 15:57:11 UTC 2026 mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC amd64
>Description:
When translating from NetBSD's siginfo to the Linux version of the struct, the si_pid member is not filled out when si_code is SI_QUEUE. Instead, the line that fills out si_uid is duplicated.
Probably a copy/paste error.
>How-To-Repeat:
Apply the fix patches from PR61004, then follow the reproduction steps in that same PR, and the test will fail this time with the error "si_pid != getpid()"
>Fix:
diff --git a/sys/compat/linux/common/linux_signal.c b/sys/compat/linux/common/linux_signal.c
index 169e1032e08c..a6c885d6c6a1 100644
--- a/sys/compat/linux/common/linux_signal.c
+++ b/sys/compat/linux/common/linux_signal.c
@@ -213,7 +213,7 @@ native_to_linux_siginfo(linux_siginfo_t *lsi, const struct _ksiginfo *ksi)
case SI_TIMER:
case SI_QUEUE:
- lsi->lsi_uid = ksi->_reason._rt._uid;
+ lsi->lsi_pid = ksi->_reason._rt._pid;
lsi->lsi_uid = ksi->_reason._rt._uid;
lsi->lsi_value.sival_ptr = ksi->_reason._rt._value.sival_ptr;
break;
>Audit-Trail:
From: "Christos Zoulas" <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/61005 CVS commit: src/sys/compat/linux/common
Date: Sun, 15 Nov 2026 17:37:34 -0500
Module Name: src
Committed By: christos
Date: Sun Nov 15 22:37:34 UTC 2026
Modified Files:
src/sys/compat/linux/common: linux_signal.c
Log Message:
PR/61005: Bobby Bingham: compat_linux fails to set si_pid when delivering
SI_QUEUE signal to Linux process because of cut-n-paste mistake
To generate a diff of this commit:
cvs rdiff -u -r1.92 -r1.93 src/sys/compat/linux/common/linux_signal.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.