From owner-freebsd-current@FreeBSD.ORG Fri Aug 15 08:20:35 2003 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 D819737B448 for ; Fri, 15 Aug 2003 08:20:32 -0700 (PDT) Received: from smtp.goamerica.net (ny-mx-01.goamerica.net [208.200.67.108]) by mx1.FreeBSD.org (Postfix) with ESMTP id E5C1043FCB for ; Fri, 15 Aug 2003 08:20:31 -0700 (PDT) (envelope-from eaja@erols.com) Received: from localhost (165.sub-166-141-30.myvzw.com [166.141.30.165]) by smtp.goamerica.net (8.12.8/8.12.8) with SMTP id h7FFKGnd005828; Fri, 15 Aug 2003 11:20:18 -0400 (EDT) Date: Fri, 15 Aug 2003 11:18:09 -0400 From: Eric Jacobs To: John-Mark Gurney , freebsd-current@freebsd.org Message-Id: <20030815111809.06960905.eaja@erols.com> In-Reply-To: <20030814173807.GR10708@funkthat.com> References: <1059835661.1198.7.camel@Twoflower.liebende.de> <1060185309.676.1.camel@Twoflower.liebende.de> <1060504397.777.15.camel@syrenna.deep-ocean.local> <20030814110113.4d238ddd.eaja@erols.com> <20030814173807.GR10708@funkthat.com> X-Mailer: Sylpheed version 0.8.5 (GTK+ 1.2.10; i386-portbld-freebsd4.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: usbd does not use detach 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: Fri, 15 Aug 2003 15:20:36 -0000 On Thu, 14 Aug 2003 10:38:07 -0700 John-Mark Gurney wrote: > > This is a bit more complex than this. There are many more layers between > usb and VFS. For USB umass devices, they proxy to cam, which then is an > interface to da which is a provider for geom which then provides the > final device for ufs to mount. So, each and every one of those steps > need to be taught about this. Right now, very few things use newbus > even though they should. This is a problem of them existing before > newbus was nailed down. CAM doesn't use newbus for any of it's device > management (scsi device, not HBA attachment). Yes, I'm aware that there are more layers. Propogating the flag value down is trivial. The major deficiency of CAM and GEOM is that errors can't be sent back up. For example, we have this scenario: # mount /dev/da0s1a /mnt # mounting a USB hard drive # cd /mnt # in use # kldunload umass # oops! it succeeds # Ideally, I'd love to see an enhanced newbus provide the One True Framework for attaching and detaching both devices and device clients. Unfortunately, it seems like it would take a substantial redesign to get there from this point. Eric