From owner-freebsd-stable@FreeBSD.ORG Thu Jun 23 10:42:34 2005 Return-Path: X-Original-To: freebsd-stable@FreeBSD.org Delivered-To: freebsd-stable@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EDED416A41C; Thu, 23 Jun 2005 10:42:34 +0000 (GMT) (envelope-from glebius@FreeBSD.org) Received: from relay.bestcom.ru (relay.bestcom.ru [217.72.144.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4F44343D58; Thu, 23 Jun 2005 10:42:33 +0000 (GMT) (envelope-from glebius@FreeBSD.org) Received: from cell.sick.ru (root@cell.sick.ru [217.72.144.68]) by relay.bestcom.ru (8.13.1/8.12.9) with ESMTP id j5NAgVDw087741 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Thu, 23 Jun 2005 14:42:31 +0400 (MSD) (envelope-from glebius@FreeBSD.org) Received: from cell.sick.ru (glebius@localhost [127.0.0.1]) by cell.sick.ru (8.13.1/8.12.8) with ESMTP id j5NAgUeF061461 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 23 Jun 2005 14:42:31 +0400 (MSD) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.sick.ru (8.13.1/8.13.1/Submit) id j5NAgU7Q061460; Thu, 23 Jun 2005 14:42:30 +0400 (MSD) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.sick.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Thu, 23 Jun 2005 14:42:30 +0400 From: Gleb Smirnoff To: Andre Oppermann Message-ID: <20050623104230.GB61389@cell.sick.ru> References: <20050621070427.GA738@obiwan.tataz.chchile.org> <20050621090701.GB34406@cell.sick.ru> <20050621105154.GA36538@cell.sick.ru> <42B961B9.7A5856B3@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <42B961B9.7A5856B3@freebsd.org> User-Agent: Mutt/1.5.6i X-Virus-Scanned: ClamAV version devel-20050125, clamav-milter version 0.80ff on relay.bestcom.ru X-Virus-Status: Clean Cc: qingli@FreeBSD.org, sam@FreeBSD.org, Jeremie Le Hen , freebsd-stable@FreeBSD.org Subject: Re: panic in RELENG_5 UMA 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: Thu, 23 Jun 2005 10:42:35 -0000 On Wed, Jun 22, 2005 at 03:03:53PM +0200, Andre Oppermann wrote: A> > Fixing this one is harder. We take la from unlocked rtentry obtained via A> > rt_check(), or from arplookup(). The latter drops lock on rtentry, too. A> > Then we do some work and use this la. It may have already been freed in A> > arp_rtrequest(), the RTM_DELETE case. A> > A> > I see two approaches here: A> > A> > 1) Protecting llinfo with route lock. In this case we need rt_check() A> > to return locked *rt (just reference won't help). We also need A> > arplookup() to return locked rt. And do not unlock it withing all A> > arpresolve() and a big part of in_arpinput() functions. A> A> I think for 5-stable this is the way to go. What about fixing it step by step? The patch attached to my previous message fixes the panic report by Jeremie, I suppose. It is race between output path and input path, that can occur anytime in runtime. The race that is not fixed by my patch (discussed above) is between output path and RTM_DELETE message, is less critical - it can occur only when administrator runs arp -d. Can you please review my patch? I think we should commit it first, and then work on the second race. -- Totus tuus, Glebius. GLEBIUS-RIPN GLEB-RIPE