From owner-freebsd-current@FreeBSD.ORG Mon Jul 19 22:35:53 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 224A416A4F5; Mon, 19 Jul 2004 22:35:53 +0000 (GMT) Received: from harmony.village.org (rover.village.org [168.103.84.182]) by mx1.FreeBSD.org (Postfix) with ESMTP id C1DFB43D31; Mon, 19 Jul 2004 22:35:52 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.12.11/8.12.11) with ESMTP id i6JMZWXb034803; Mon, 19 Jul 2004 16:35:32 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Mon, 19 Jul 2004 16:35:36 -0600 (MDT) Message-Id: <20040719.163536.81896269.imp@bsdimp.com> To: pjd@FreeBSD.ORG From: "M. Warner Losh" In-Reply-To: <20040719173819.GI57678@darkness.comp.waw.pl> References: <20040719145745.GH57678@darkness.comp.waw.pl> <20040719102139.N59702@carver.gumbysoft.com> <20040719173819.GI57678@darkness.comp.waw.pl> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit cc: freebsd-current@FreeBSD.ORG Subject: Re: Unloading USB driver while device is attached. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 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: Mon, 19 Jul 2004 22:35:53 -0000 In message: <20040719173819.GI57678@darkness.comp.waw.pl> Pawel Jakub Dawidek writes: : On Mon, Jul 19, 2004 at 10:23:16AM -0700, Doug White wrote: : +> Theres a discussion going on in -arch about making kldunload a bit more : +> careful about cleaning up before detaching. In the interim adding a : +> method that just vetos any unload request would prevent this from : +> occuring, but also preclude unloading the driver. :) : : Yeah, but even on 'kldunload -f' it should be possible to clean up : and avoid panic on next load. kldunload -f isn't supported at this point :-) Or more accurately, there's no hook into the driver system (newbus). And even if there was, usb has been poorly integrated into newbus in the past, so it likely still would do bad things. Eg, -f isn't going to save you. umass should be fixed. Warner