From owner-cvs-src@FreeBSD.ORG Tue Oct 19 21:51:27 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0BEC316A4CF for ; Tue, 19 Oct 2004 21:51:27 +0000 (GMT) Received: from c00l3r.networx.ch (c00l3r.networx.ch [62.48.2.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2F78C43D55 for ; Tue, 19 Oct 2004 21:51:26 +0000 (GMT) (envelope-from andre@freebsd.org) Received: (qmail 62327 invoked from network); 19 Oct 2004 21:50:21 -0000 Received: from unknown (HELO freebsd.org) ([62.48.0.53]) (envelope-sender ) by c00l3r.networx.ch (qmail-ldap-1.03) with SMTP for ; 19 Oct 2004 21:50:21 -0000 Message-ID: <41758C62.E27112C0@freebsd.org> Date: Tue, 19 Oct 2004 23:51:30 +0200 From: Andre Oppermann X-Mailer: Mozilla 4.8 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: Robert Watson References: <200410192135.i9JLZgmv002301@repoman.freebsd.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit cc: cvs-src@FreeBSD.org cc: src-committers@FreeBSD.org cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/netinet ip_divert.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Oct 2004 21:51:27 -0000 Robert Watson wrote: > > rwatson 2004-10-19 21:35:42 UTC > > FreeBSD src repository > > Modified files: > sys/netinet ip_divert.c > Log: > Annotate a newly introduced race present due to the unloading of > protocols: it is possible for sockets to be created and attached > to the divert protocol between the test for sockets present and > successful unload of the registration handler. We will need to > explore more mature APIs for unregistering the protocol and then > draining consumers, or an atomic test-and-unregister mechanism. Thanks. I'll commit a little extended locking of that section in a few minutes. Is it possible for someone else to spin on the lock while we are holding it? If yes, it would be impossible to destroy the lock on the next line. The same problem is then resident in ipfw unloading as well. -- Andre