From owner-svn-src-head@FreeBSD.ORG Thu Aug 23 03:43:01 2012 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 636081065674; Thu, 23 Aug 2012 03:43:01 +0000 (UTC) (envelope-from ken@kdm.org) Received: from nargothrond.kdm.org (nargothrond.kdm.org [70.56.43.81]) by mx1.freebsd.org (Postfix) with ESMTP id 0CFF78FC16; Thu, 23 Aug 2012 03:43:00 +0000 (UTC) Received: from nargothrond.kdm.org (localhost [127.0.0.1]) by nargothrond.kdm.org (8.14.2/8.14.2) with ESMTP id q7N3h0QN097115; Wed, 22 Aug 2012 21:43:00 -0600 (MDT) (envelope-from ken@nargothrond.kdm.org) Received: (from ken@localhost) by nargothrond.kdm.org (8.14.2/8.14.2/Submit) id q7N3gxWI097114; Wed, 22 Aug 2012 21:42:59 -0600 (MDT) (envelope-from ken) Date: Wed, 22 Aug 2012 21:42:59 -0600 From: "Kenneth D. Merry" To: Gleb Smirnoff Message-ID: <20120823034259.GA97058@nargothrond.kdm.org> References: <201208021357.q72DvoFJ088426@svn.freebsd.org> <20120802213344.GF70185@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20120802213344.GF70185@FreeBSD.org> User-Agent: Mutt/1.4.2i Cc: svn-src-head@FreeBSD.org, "Bjoern A. Zeeb" , svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r238990 - in head/sys: net netinet netinet6 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Aug 2012 03:43:01 -0000 On Fri, Aug 03, 2012 at 01:33:44 +0400, Gleb Smirnoff wrote: > On Thu, Aug 02, 2012 at 04:46:42PM +0000, Bjoern A. Zeeb wrote: > B> On Thu, 2 Aug 2012, Gleb Smirnoff wrote: > B> > B> > Author: glebius > B> > Date: Thu Aug 2 13:57:49 2012 > B> > New Revision: 238990 > B> > URL: http://svn.freebsd.org/changeset/base/238990 > B> > > B> > Log: > B> > Fix races between in_lltable_prefix_free(), lla_lookup(), > B> > llentry_free() and arptimer(): > B> > > B> > o Use callout_init_rw() for lle timeout, this allows us safely > B> > disestablish them. > B> > - This allows us to simplify the arptimer() and make it > B> > race safe. > B> > o Consistently use ifp->if_afdata_lock to lock access to > B> > linked lists in the lle hashes. > B> > o Introduce new lle flag LLE_LINKED, which marks an entry that > B> > is attached to the hash. > B> > - Use LLE_LINKED to avoid double unlinking via consequent > B> > calls to llentry_free(). > B> > - Mark lle with LLE_DELETED via |= operation istead of =, > B> > so that other flags won't be lost. > B> > o Make LLE_ADDREF(), LLE_REMREF() and LLE_FREE_LOCKED() more > B> > consistent and provide more informative KASSERTs. > B> > > B> > The patch is a collaborative work of all submitters and myself. > B> > B> Quoting from 2 year old memory you just introduced a possible deadlock > B> on tbale (or with that networkstack) teardown adding the extra af_data > B> write locking to the table walk. > > Can you please give more details? I didn't get it. What else needs > afdata lock and what does it hold which is held by table walk. Is there a deadlock in that particular change? If so, what will it take to fix it? Thanks, Ken -- Kenneth Merry ken@FreeBSD.ORG