From owner-svn-src-all@FreeBSD.ORG Sat Oct 16 20:15:08 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3384B106566B; Sat, 16 Oct 2010 20:15:08 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mail.cksoft.de (mail.cksoft.de [IPv6:2001:4068:10::3]) by mx1.freebsd.org (Postfix) with ESMTP id AD7788FC12; Sat, 16 Oct 2010 20:15:07 +0000 (UTC) Received: from localhost (amavis.fra.cksoft.de [192.168.74.71]) by mail.cksoft.de (Postfix) with ESMTP id A5BC041C71D; Sat, 16 Oct 2010 22:15:06 +0200 (CEST) X-Virus-Scanned: amavisd-new at cksoft.de Received: from mail.cksoft.de ([192.168.74.103]) by localhost (amavis.fra.cksoft.de [192.168.74.71]) (amavisd-new, port 10024) with ESMTP id Bvetxud-+m+j; Sat, 16 Oct 2010 22:15:06 +0200 (CEST) Received: by mail.cksoft.de (Postfix, from userid 66) id EDC9541C72C; Sat, 16 Oct 2010 22:15:05 +0200 (CEST) Received: from maildrop.int.zabbadoz.net (maildrop.int.zabbadoz.net [10.111.66.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.int.zabbadoz.net (Postfix) with ESMTP id C00514448F3; Sat, 16 Oct 2010 20:11:10 +0000 (UTC) Date: Sat, 16 Oct 2010 20:11:10 +0000 (UTC) From: "Bjoern A. Zeeb" X-X-Sender: bz@maildrop.int.zabbadoz.net To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org In-Reply-To: <201010161953.o9GJrN4q088035@svn.freebsd.org> Message-ID: <20101016195748.E10185@maildrop.int.zabbadoz.net> References: <201010161953.o9GJrN4q088035@svn.freebsd.org> X-OpenPGP-Key: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Subject: Re: svn commit: r213932 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Oct 2010 20:15:08 -0000 On Sat, 16 Oct 2010, Bjoern A. Zeeb wrote: > Author: bz > Date: Sat Oct 16 19:53:22 2010 > New Revision: 213932 > URL: http://svn.freebsd.org/changeset/base/213932 > > Log: > MfP4 CH182763 (original version): > > Make it harder to exploit certain in_control() related races between the > intiial lookup at the beginning and the time we will remove the entry > from the lists by re-checking that entry is still in the list before > trying to remove it. > > (*) It is believed that with the current code and locking strategy we > cannot completely fix all race. Just as a follow-up: a couple of weeks ago I spent too much time on this to come to that conclusion. Try running 3 or more parallel ifconfig loops adding and removing the very same address and it's only matter of seconds. In case someone is interested I have a way huger patch of unknown state around but it's always only shifiting the problem. A possibly better fix to change the locking strategy is currently under discussion. > Reported by: Nima Misaghian (nima_misa hotmail.com) on net@ 20100817 > Tested by: Nima Misaghian (nima_misa hotmail.com) (original version) > PR: kern/146250 > Submitted by: Mikolaj Golub (to.my.trociny gmail.com) (different version) > MFC after: 1 week > > Modified: > head/sys/netinet/in.c -- Bjoern A. Zeeb Welcome a new stage of life.