From owner-freebsd-current@FreeBSD.ORG Thu Jul 5 14:48:56 2007 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A579716A41F for ; Thu, 5 Jul 2007 14:48:56 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from cs1.cs.huji.ac.il (cs1.cs.huji.ac.il [132.65.16.10]) by mx1.freebsd.org (Postfix) with ESMTP id 5F7BD13C44B for ; Thu, 5 Jul 2007 14:48:56 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by cs1.cs.huji.ac.il with esmtp id 1I6SAN-0000by-Bt; Thu, 05 Jul 2007 17:18:43 +0300 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Kostik Belousov In-reply-to: <20070703180141.GJ2200@deviant.kiev.zoral.com.ua> References: <20070703180141.GJ2200@deviant.kiev.zoral.com.ua> Comments: In-reply-to Kostik Belousov message dated "Tue, 03 Jul 2007 21:01:41 +0300." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 05 Jul 2007 17:18:43 +0300 From: Danny Braniss Message-ID: Cc: current@freebsd.org Subject: Re: HEADS UP: destroy_dev_sched() KPI in the tree X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jul 2007 14:48:56 -0000 > Today, I got re@ permission and committed the destroy_dev_sched() KPI > into the tree. As suggested by Nate Lawson, destroy_dev() tries to > auto-detect "devdrn" deadlock condition and transforms destroy_dev() > from d_close() csw method into destroy_dev_sched(). I together with > Peter Holm tried to test the change as thoroughly as possible. > > The obvious problematic area are the races between device driver > module unload and destroy_dev_sched(). At least smb(4) definitely > has that race that shall be worked around by draining events with > drain_dev_clone_events() and destroy_dev_drain(&cdevsw); see snp(4) > change for example. > > Please, report issues caused by the patch to the list with me Cc:ed. > Change of autodetection of deadlock in destroy_dev() was made in separate > commit for ease of reverting. and today I got a chance to check it, and it works for me (iscsi_initiator). danny