From owner-freebsd-stable@FreeBSD.ORG Mon Mar 17 11:57:29 2008 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1EEC81065672; Mon, 17 Mar 2008 11:57:29 +0000 (UTC) (envelope-from imb@protected-networks.net) Received: from sarah.protected-networks.net (sarah.protected-networks.net [64.46.156.146]) by mx1.freebsd.org (Postfix) with ESMTP id D31908FC22; Mon, 17 Mar 2008 11:57:28 +0000 (UTC) (envelope-from imb@protected-networks.net) Received: from toshi.auburn.protected-networks.net (toshi.auburn.protected-networks.net [202.12.127.84]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "Iain Michael Butler", Issuer "Protected Networks Certificate Authority" (verified OK)) (Authenticated sender: imb) by sarah.protected-networks.net (Postfix) with ESMTPSA id 5640260E2; Mon, 17 Mar 2008 07:42:14 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=protected-networks.net; s=200705; t=1205754134; bh=q9AcbnXrAO9opw Ejm307C0f6vMfd6shkn1foPKU2NuM=; h=DomainKey-Signature:Message-ID: Date:From:User-Agent:MIME-Version:To:CC:Subject:References: In-Reply-To:X-Enigmail-Version:OpenPGP:Content-Type; b=Y27Z6J3dGmw 75UAHkVsK+7R2ISI72Bt5snusc8tdQF8J0SdVsBxcMLWcABDBGeg7GaCLDRX3E3kjg4 8FJsbzz8DoKLpPWecdTZPJMnrYnl2BMlDcw80RafWp/7grXSfF DomainKey-Signature: a=rsa-sha1; s=200509; d=protected-networks.net; c=nofws; q=dns; h=message-id:date:from:user-agent:mime-version:to:cc:subject: references:in-reply-to:x-enigmail-version:openpgp:content-type; b=nauPm+GQ8YZSPvi+1X7x0l6H213vVdwhrKB8c2GdP3XnYnaFbJGwGT/gnEhmrhStX QbJFFMVX9RClZmkNSsn0hK6VR10R3S53G4g4JN76zZHo1BUxL88VJnSzPOu9E40 Message-ID: <47DE5915.50703@protected-networks.net> Date: Mon, 17 Mar 2008 07:42:13 -0400 From: Michael Butler User-Agent: Thunderbird 2.0.0.12 (X11/20080311) MIME-Version: 1.0 To: Lawrence Farr References: <200803141546.10569.jhb@freebsd.org> <01fc01c8881b$075b5620$16120260$@co.uk> In-Reply-To: <01fc01c8881b$075b5620$16120260$@co.uk> X-Enigmail-Version: 0.95.6 OpenPGP: id=0442D492 Content-Type: multipart/mixed; boundary="------------060704070308050902000203" Cc: freebsd-stable@freebsd.org, 'John Baldwin' Subject: Re: bin/121684: dump frequently hangs X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Mar 2008 11:57:29 -0000 This is a multi-part message in MIME format. --------------060704070308050902000203 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Lawrence Farr wrote: > I couldn't get this to apply cleanly against 7, is it safe to use rev > 1.48 on 7? I have 3 machines here that hang whilst dumping and I'd > like to test the patch. For RELENG_7, I'm using the attached. Apply it from /usr, Michael --------------060704070308050902000203 Content-Type: text/x-patch; name="subr_sleepqueue.c.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="subr_sleepqueue.c.diff" *** src/sys/kern/subr_sleepqueue.c.orig Thu Mar 6 11:13:14 2008 --- src/sys/kern/subr_sleepqueue.c Fri Mar 14 21:58:58 2008 *************** *** 403,414 **** mtx_unlock(&ps->ps_mtx); } /* ! * Lock sleepq chain before unlocking proc ! * without this, we could lose a race. */ mtx_lock_spin(&sc->sc_lock); PROC_UNLOCK(p); thread_lock(td); if (ret == 0) { if (!(td->td_flags & TDF_INTERRUPT)) { sleepq_switch(wchan); --- 403,417 ---- mtx_unlock(&ps->ps_mtx); } /* ! * Lock the per-process spinlock prior to dropping the PROC_LOCK ! * to avoid a signal delivery race. PROC_LOCK, PROC_SLOCK, and ! * thread_lock() are currently held in tdsignal(). */ + PROC_SLOCK(p); mtx_lock_spin(&sc->sc_lock); PROC_UNLOCK(p); thread_lock(td); + PROC_SUNLOCK(p); if (ret == 0) { if (!(td->td_flags & TDF_INTERRUPT)) { sleepq_switch(wchan); --------------060704070308050902000203--