NetBSD Problem Report #38649

From martin@aprisoft.de  Tue May 13 08:39:32 2008
Return-Path: <martin@aprisoft.de>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by narn.NetBSD.org (Postfix) with ESMTP id 461D963B293
	for <gnats-bugs@gnats.NetBSD.org>; Tue, 13 May 2008 08:39:32 +0000 (UTC)
Message-Id: <20080513083930.44750AF580E@emmas.aprisoft.de>
Date: Tue, 13 May 2008 10:39:30 +0200 (CEST)
From: martin@duskware.de
Reply-To: martin@duskware.de
To: gnats-bugs@gnats.NetBSD.org
Subject: locking prboblem with ptrace on SMP machines
X-Send-Pr-Version: 3.95

>Number:         38649
>Category:       kern
>Synopsis:       locking prboblem with ptrace on SMP machines
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    kern-bug-people
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue May 13 08:40:00 +0000 2008
>Closed-Date:    Sun May 18 21:48:44 +0000 2008
>Last-Modified:  Sun May 18 21:48:44 +0000 2008
>Originator:     Martin Husemann
>Release:        NetBSD 4.99.62
>Organization:
The NetBSD Foundation, Inc.
>Environment:
System: NetBSD martins.aprisoft.de 4.99.62 NetBSD 4.99.62 (MARTINS) #2: Mon May 12 15:40:19 CEST 2008 martin@martins.aprisoft.de:/usr/src/sys/arch/amd64/compile/MARTINS amd64
Architecture: x86_64
Machine: amd64
>Description:

Run "gdb -p ..." on a -current SMP system with LOCKDEBUG kernel:

Mutex error: mutex_vector_exit: assertion failed: MUTEX_OWNER(mtx->mtx_owner) == curthread

lock address : 0xffff80004bc86500 type     :     sleep/adaptive
shared holds :                  0 exclusive:                  0
shares wanted:                  0 exclusive:                  0
current cpu  :                  1 last held:                  1
current lwp  : 0xffff80004fdc2b60 last held: 000000000000000000
last locked  : 0xffffffff80266793 unlocked : 0xffffffff802667c7
initialized  : 0xffffffff802255ae                              
owner field  : 000000000000000000 wait/spin:                0/0

Turnstile chain at 0xffffffff80558700.
=> No active turnstile for this lock. 

panic: LOCKDEBUG
Stopped in pid 776.1 (gdb) at   netbsd:breakpoint+0x5:  leave


>How-To-Repeat:
s/a

>Fix:
n/a

>Release-Note:

>Audit-Trail:
From: YAMAMOTO Takashi <yamt@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/38649 CVS commit: src/sys/kern
Date: Tue, 13 May 2008 09:16:11 +0000 (UTC)

 Module Name:	src
 Committed By:	yamt
 Date:		Tue May 13 09:16:11 UTC 2008

 Modified Files:
 	src/sys/kern: sys_process.c

 Log Message:
 sys_ptrace: fix a locking botch.  PR/38649 from Martin Husemann.


 To generate a diff of this commit:
 cvs rdiff -r1.139 -r1.140 src/sys/kern/sys_process.c

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: open->closed
State-Changed-By: martin@NetBSD.org
State-Changed-When: Sun, 18 May 2008 21:48:44 +0000
State-Changed-Why:
yamt fixed it


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(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.