NetBSD Problem Report #55849

From www@netbsd.org  Tue Dec  8 08:54:33 2020
Return-Path: <www@netbsd.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 1FAEC1A9217
	for <gnats-bugs@gnats.NetBSD.org>; Tue,  8 Dec 2020 08:54:33 +0000 (UTC)
Message-Id: <20201208085431.AC9AB1A9239@mollari.NetBSD.org>
Date: Tue,  8 Dec 2020 08:54:31 +0000 (UTC)
From: s-yamaguchi@iij.ad.jp
Reply-To: s-yamaguchi@iij.ad.jp
To: gnats-bugs@NetBSD.org
Subject: panic LOCKDEBUG in agr(4)
X-Send-Pr-Version: www-1.0

>Number:         55849
>Category:       kern
>Synopsis:       panic LOCKDEBUG in agr(4)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Dec 08 08:55:00 +0000 2020
>Originator:     Shoichi Yamaguchi
>Release:        NetBSD 9.99.76
>Organization:
Internet Initiative Japan Inc.
>Environment:
NetBSD hidden 9.99.76 NetBSD 9.99.76 (DEV) #13: Fri Dec  4 14:29:29 JST 2020  hidden:obj/sys/arch/amd64/compile/DEV amd64

>Description:
# [ 49784.7497435] Mutex error: mutex_vector_enter,516: spin lock held 
[ 49784.7497435] lock address : 0xfffff185a6430550 type     :               spin
[ 49784.7497435] initialized  : 0xffffffff80e2085f
[ 49784.7497435] shared holds :                  0 exclusive:                  1
[ 49784.7497435] shares wanted:                  0 exclusive:                  0
[ 49784.7497435] relevant cpu :                  0 last held:                  0
[ 49784.7497435] relevant lwp : 0xfffff185a64aaac0 last held: 0xfffff185a64aaac0
[ 49784.7497435] last locked* : 0xffffffff80e226a2 unlocked : 0xffffffff80cdab80
[ 49784.7497435] owner field  : 0x0000000000010600 wait/spin:                0/1

[ 49784.7654397] panic: LOCKDEBUG: Mutex error: mutex_vector_enter,516: spin lock held
[ 49784.7654397] cpu0: Begin traceback...
[ 49784.7654397] vpanic() at netbsd:vpanic+0x156
[ 49784.7654397] snprintf() at netbsd:snprintf
[ 49784.7654397] lockdebug_more() at netbsd:lockdebug_more
[ 49784.7654397] mutex_enter() at netbsd:mutex_enter+0x392
[ 49784.7654397] ifmedia_ioctl() at netbsd:ifmedia_ioctl+0x268
[ 49784.7654397] iavf_ioctl() at if_iavf:iavf_ioctl+0x59
[ 49784.7654397] agr_port_getmedia() at netbsd:agr_port_getmedia+0x60
[ 49784.7654397] agrport_monitor() at netbsd:agrport_monitor+0x76
[ 49784.7654397] agrtimer_port_tick() at netbsd:agrtimer_port_tick+0x13
[ 49784.7654397] agr_port_foreach() at netbsd:agr_port_foreach+0x30
[ 49784.7654397] agrtimer_work() at netbsd:agrtimer_work+0x47
[ 49784.7654397] workqueue_worker() at netbsd:workqueue_worker+0xd7
[ 49784.7654397] cpu0: End traceback...
[ 49784.7654397] rebooting...
>How-To-Repeat:
% ifconfig agr0 create
% ifconfig agr0 agrport iavf0
% ifconfig iavf0 up
% ifconfig agr0 up
>Fix:
Use an adaptive mutex for sc_lock in agr_softc, not a spin mutex

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.46 2020/01/03 16:35:01 leot Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2020 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.